[Suggestion] Check the HF and the script config in conversion tool
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 8.5k
- Forks
- 1.3k
- Avg merge
- 5h 36m
- Merged PRs (30d)
- 22
Description
I absolutely love your 0.2.0 update! During our usage, some colleagues mistakenly modify configurations in scripts/models, but tools/convert_hf_to_torch_dist.py doesn't seem to check whether the HF config matches the config in scripts/models. We noticed that there's a dedicated function called hf_validate_args in utils/arguments.py that performs this validation. If there are issues with the weights after conversion, it can cause silent errors during training (no error messages at all!). Maybe this validation check can be added to the conversion tool. Thank you!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with tools/convert_hf_to_torch_dist.py and inspect how it handles configurations before conversion. Read hf_validate_args in utils/arguments.py to understand the existing validation, then ensure the conversion tool checks the HF configuration against scripts/models and reports mismatches before producing weights.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- machine-learning, tooling
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 52/100