Repository navigation
Conversation
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
ad065c7 to
fcd62fb
Compare
fcd62fb to
8fff69d
Compare
|
@b8zhong could you take a look at this smaller loader-verification slice if you have bandwidth? It adds the opt-in full-checkpoint check without changing model behavior, so it can land ahead of the broader cleanup; a |
Separate "load the weights" from "verify the checkpoint was complete". A new `_load_and_verify_weights` runs after a full load and fails fast on any required parameter that was left uninitialized -- computed as pure set algebra (`unloaded_required_params`), with legitimately-absent params (PP-distributed, quant/kv scales, role-specific) excluded by an optional per-model `is_optional_weight(name)` predicate. Gated by a per-model `verify_weights_on_load` flag (default off): no model opts in here, so this is dormant -- zero behavior change. It is the mechanism for moving the "weights are not initialized from checkpoints" diagnostic out of individual models' `load_weights` (where it false-positives when the online/RL weight-update path reuses `load_weights` with partial tensor slices) and into the loader, which runs it only on full checkpoint loads. See RFC sgl-project#28585. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
8fff69d to
51aac28
Compare
|
Thanks @EazyReal. Closing this because you have 20 PRs open and none updated in 7 days, over our soft cap of 5 for idle PRs. Reopen the two or three you most want reviewed - a short active set moves faster than a long idle one. Some directories moved recently, so an older branch may need retargeting: |
Motivation
Some model
load_weightsmethods both copy tensors and check full-checkpoint completeness. Partial update paths call the same methods with only a slice of tensors, so the completeness check belongs in the full-checkpoint loader path instead.Changes
_load_and_verify_weightsfor full checkpoint load paths.unloaded_required_paramsfor required-minus-loaded set computation.verify_weights_on_load.No model opts in here, so this PR is behavior-preserving. Model migrations can land separately after RFC #28585 is accepted.
Verification
test/registered/unit/model_loader/test_load_and_verify_weights.py.git diff --check,py_compileon touched files, and focused Ruff checks for the new helper/test.Full final-state implementation for context: #29323.
CI States
Latest PR Test (Base): ❌ Run #28888248116
Latest PR Test (Extra): ❌ Run #28888247861