Skip to content

train: hardened WSD defined in-config, W&B experiment tag, mode=validate on EMA weights - #713

Draft
RyanPCo wants to merge 4 commits into
ryanco/val-exact-readsfrom
ryanco/wsd-validate-mode
Draft

RyanPCo wants to merge 4 commits into
ryanco/val-exact-readsfrom
ryanco/wsd-validate-mode

Conversation

@RyanPCo

@RyanPCo RyanPCo commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

scheduler: harden warmup_stable_decay (min_factor floor, argument checks)

Decay now ends at an optional min_factor instead of 0, arguments are
validated, and a zero-length warmup or decay no longer divides by zero.
Signature stays compatible with existing callers.

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF

configs: WSD recipes define their scheduler in-config via _scheduler_reset

A Hydra merge onto the model's LinearLR keeps its arguments, so the launch
scripts swapped WSD in from the CLI. _scheduler_reset (ported from #710) nulls
model.scheduler in the defaults chain so op2's self can define WSD, and every
recipe built on it sets the phases the launchers computed (1k or 500 warmup,
linear decay over the last 20% of max_epochs x 100 steps; overfit1 6k steps).
The full* configs had no launcher and now follow the same rule. The generators
emit the same blocks. The launchers' '~model.scheduler' swap still works.

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF

trainHydra: tag W&B runs with their hydra_configs/experiments/

Ported from #710: a config composed as experiments// gets
appended to logger.wandb.tags. Skipped when Hydra is not initialized
(train() called directly from tests).

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF

trainHydra: mode=validate scores one checkpoint through the training val heads

Ported from #710 without its metric_sampling, named validation sets or
open-loop pieces: builds the same val heads as training (train_viz,
unseen_op_valid, extra_valid), runs trainer.validate on one device with no
logger, and writes /validation_metrics.json.

Fixes the port's EMA gap: a checkpoint with checkpoint["ema"] is scored with
the EMA weights, as training validated it, even under a config without
model.ema enabled. limit_val_batches is scaled by the training world size so
one rank covers the frames the metric loaders were built for, and a validate
job never swaps its ckpt_path for a requeue's last.ckpt.

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF

Ported from ideas in #710 (no IDs taken). Combined stack: ruff clean; 562 targeted unit tests pass on CPU; no GPU smoke run yet.

🤖 Generated with Claude Code

https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF

RyanPCo and others added 4 commits October 12, 2026 21:55
…cks)

Decay now ends at an optional min_factor instead of 0, arguments are
validated, and a zero-length warmup or decay no longer divides by zero.
Signature stays compatible with existing callers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF
…reset

A Hydra merge onto the model's LinearLR keeps its arguments, so the launch
scripts swapped WSD in from the CLI. _scheduler_reset (ported from #710) nulls
model.scheduler in the defaults chain so op2's _self_ can define WSD, and every
recipe built on it sets the phases the launchers computed (1k or 500 warmup,
linear decay over the last 20% of max_epochs x 100 steps; overfit1 6k steps).
The full* configs had no launcher and now follow the same rule. The generators
emit the same blocks. The launchers' '~model.scheduler' swap still works.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF
Ported from #710: a config composed as experiments/<folder>/<name> gets
<folder> appended to logger.wandb.tags. Skipped when Hydra is not initialized
(train() called directly from tests).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF
…val heads

Ported from #710 without its metric_sampling, named validation sets or
open-loop pieces: builds the same val heads as training (train_viz,
unseen_op_valid, extra_valid), runs trainer.validate on one device with no
logger, and writes <run dir>/validation_metrics.json.

Fixes the port's EMA gap: a checkpoint with checkpoint["ema"] is scored with
the EMA weights, as training validated it, even under a config without
model.ema enabled. limit_val_batches is scaled by the training world size so
one rank covers the frames the metric loaders were built for, and a validate
job never swaps its ckpt_path for a requeue's last.ckpt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X86xQuci4asKUkiCwqMiKF

RyanPCo commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor Author

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@RyanPCo RyanPCo changed the title scheduler: harden warmup_stable_decay (min_factor floor, argument checks) train: hardened WSD defined in-config, W&B experiment tag, mode=validate on EMA weights Oct 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant