You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
delay_io_train was refactored so the default optimizer is bayesian (with scipy.optimize methods via the else branch). The original compass-search tuning loop was never removed.
In modpods/train.py, after the first results[num_transforms] = {...} + early-stopping check, there is an unconditional continue. That continue makes everything after it unreachable, in particular:
the for iterations in range(0, max_iter): compass-search candidate loop (sooner/later/shape_up/shape_down/scaled_up/scaled_down/rounder/sharper),
So compass search is already deprecated/dead code (see also the merged #20), never invoked by any test, and it duplicates the final_model/results logic above the continue.
Proposal: delete the unreachable block (keep the continue as normal loop iteration; remove the dead compass tuning loop and the duplicate second final_model/results/early-stop).
Cost: Low (no reachable behavior changes; tests only use bayesian/de/da/scipy).
Benefit: High (removes ~400 LOC / ~half of delay_io_train; removes contradictory duplicate logic). A cleanup follow-up to the closed make modpods as small as possible #18 monolith split.
delay_io_trainwas refactored so the default optimizer isbayesian(withscipy.optimizemethods via theelsebranch). The original compass-search tuning loop was never removed.In
modpods/train.py, after the firstresults[num_transforms] = {...}+ early-stopping check, there is an unconditionalcontinue. Thatcontinuemakes everything after it unreachable, in particular:for iterations in range(0, max_iter):compass-search candidate loop (sooner/later/shape_up/shape_down/scaled_up/scaled_down/rounder/sharper),final_model = SINDY_delays_MI(...)+results[num_transforms] = {...}+ early-stopping block.So compass search is already deprecated/dead code (see also the merged #20), never invoked by any test, and it duplicates the
final_model/resultslogic above thecontinue.Proposal: delete the unreachable block (keep the
continueas normal loop iteration; remove the dead compass tuning loop and the duplicate secondfinal_model/results/early-stop).delay_io_train; removes contradictory duplicate logic). A cleanup follow-up to the closed make modpods as small as possible #18 monolith split.