poincare-hyper / src /config.py
DHDRL's picture
Rename config.py to src/config.py
63834af verified
Raw
History Blame Contribute Delete
854 Bytes
"""
Single source of truth for hyperparameters.
The Optuna-derived "best" hyperparameters were hardcoded in both run_full.py and continual_demo.py.
If the Optuna study were ever rerun and produced different best_params,
these two files would silently drift out of sync with each other and with the
actual search result — exactly the "single source of truth" violation
this project's own design rules aim to prevent. Every consumer now imports
BEST_HPARAMS from here instead of re-declaring it.
If you rerun the Optuna study (src/train.py) and get a new best result,
update ONLY this file.
"""
from __future__ import annotations
BEST_HPARAMS = dict(
lr=3.82e-4,
curvature=0.455,
hidden=96,
batch_size=8,
pred_steps=4,
w_phys=9.6e-4,
levels=2,
)
WINDOW = 4 # input window length used consistently across pretrain/PPO/env