refactor(registry): single-source the deflation-bootstrap constants (#199)
DEFLATION_N_RESAMPLES (1000) and DEFLATION_BLOCK_LEN (5) were duplicated as independent copies in aura-cli and aura-campaign — a silent-drift risk (an edit in one crate but not the other refuses nothing, it just produces a wrong deflation result). Promote a single definition into aura-registry, which owns optimize_deflated (the sole consumer of these counts); aura-cli imports it and aura-campaign re-exports it to keep its public path stable. DEFLATION_SEED stays cli-local (no campaign twin). Values unchanged; behaviour-preserving, suite green unchanged (1043/0). closes #199
This commit is contained in:
@@ -33,6 +33,7 @@ use aura_registry::{
|
||||
check_r_metric, generalization, group_families, mc_member_reports, optimize_deflated,
|
||||
optimize_plateau, rank_by, sweep_member_reports, walkforward_member_reports, FamilyKind,
|
||||
FamilyMember, Generalization, NameKind, PlateauMode, Registry, RunTraces, WriteKind,
|
||||
DEFLATION_BLOCK_LEN, DEFLATION_N_RESAMPLES,
|
||||
};
|
||||
use aura_std::{
|
||||
Add, Bias, CarryCost, ConstantCost, Delay, Ema, GatedRecorder, Gt, Latch, LinComb, LongOnly, Mul,
|
||||
@@ -65,11 +66,10 @@ const WF_REAL_IS_NS: i64 = 90 * WF_DAY_NS;
|
||||
const WF_REAL_OOS_NS: i64 = 30 * WF_DAY_NS;
|
||||
const WF_REAL_STEP_NS: i64 = 30 * WF_DAY_NS;
|
||||
|
||||
/// Trials-deflation resampling budget for walk-forward winner selection. Recorded
|
||||
/// on each winner's manifest (so `overfit_probability` is reproducible by re-run);
|
||||
/// CLI flags for these are a deferred refinement.
|
||||
const DEFLATION_N_RESAMPLES: usize = 1000;
|
||||
const DEFLATION_BLOCK_LEN: usize = 5;
|
||||
/// Fixed RNG seed for the trials-deflation reality-check bootstrap in walk-forward
|
||||
/// winner selection. Recorded on each winner's manifest (so `overfit_probability`
|
||||
/// is reproducible by re-run); a CLI flag for it is a deferred refinement. The
|
||||
/// resample count and block length are the shared `aura_registry::DEFLATION_*`.
|
||||
const DEFLATION_SEED: u64 = 0xDEF1_A7ED;
|
||||
|
||||
/// The built-in synthetic price stream: rises through t=4 then reverses, so the
|
||||
|
||||
Reference in New Issue
Block a user