Repository navigation
Conversation
… update tests Signed-off-by: Xin He <xin3.he@intel.com>
There was a problem hiding this comment.
🟡 Changes recommended
Three moderate issues remain unresolved in tensor preservation, revision-aware checkpoint resolution, and model-free routing.
2 open issues
What changed in this PR
Enhances mixed-precision checkpoint loading by preserving selected FP32 tensors during loading, casting, and materialization.
Changes:
- Adds FP32 tensor detection and restoration.
- Integrates preservation into regular and meta-model loading.
- Expands regression tests and updates model-free routing.
Open findings remain around FP32 detection, checkpoint revision handling, and model-free routing behavior.
| File | Reviewed change |
|---|---|
test/unit/common/utils/test_missing_tensors.py |
Adds mixed-precision restoration tests. |
auto_round/utils/model.py |
Integrates FP32 retention and updates routing behavior. |
auto_round/utils/missing_tensors.py |
Detects and preserves mixed-checkpoint FP32 tensors. |
auto_round/context/model.py |
Applies FP32 retention to meta-loaded models. |
Review effort: Lite
| if ( | ||
| tensor is not None | ||
| and tensor.dtype in (torch.float16, torch.bfloat16, torch.float32) | ||
| and (tensor.device.type == "meta" or tensor.dtype != torch.float32) | ||
| ): | ||
| candidates_by_shard.setdefault(shard, []).append(tensor_name) |
| return False | ||
| if explicit: | ||
| if has_static_attention_quantization: | ||
| raise ValueError("model_free=True does not support static KV or attention quantization.") |
CI Failure Analysis Report (Unit-Test-AutoRound)
New Issues (2)No.1 — 2 occurrence(s)🔍 ValueError: model_free=True does not support static KV or attention quantization.📝 Basic info
🖥️ Log excerpt✨ AI analysis
No.2 — 1 occurrence(s)🔍 assert torch.bfloat16 == torch.float32📝 Basic info
🖥️ Log excerpt✨ AI analysis
|

… update tests
Description
some weights should kept as FP32 in tuning phase
Type of Change
New feature
Related Issues
Fixes or relates to #2332
Checklist Before Submitting
/azp run Unit-Test-CUDA-AutoRound.