Intermediate-tensor distillation support
[!IMPORTANT]
TheUpdate branchbutton must only be pressed in very rare occassions. An outdated branch is never blocking the merge of a PR. Please reach out to the automation team before pressing that button.
What does this PR do ?
Add a one line overview of what this PR aims to accomplish.
Collection: LLM
Changelog
- Allow distillation losses to be specified on non-logits feature tensors
Usage
- You can potentially add a usage example below
python scripts/llm/gpt_distillation.py \
--name ${NAME} \
--teacher_path ${TEACHER} \
--student_path ${STUDENT} \
--tp_size ${TP} \
--cp_size ${CP} \
--pp_size ${PP} \
--devices ${GPUS} \
--num_nodes ${NODES} \
--log_dir ${LOG_DIR} \
--max_steps ${STEPS} \
--gbs ${GBS} \
--mbs ${MBS} \
--data_paths ${DATA_PATHS} \
--index_mapping_dir ${DATA_CACHE} \
--seq_length ${SEQ_LEN}
GitHub Actions CI
The Jenkins CI system has been replaced by GitHub Actions self-hosted runners.
The GitHub Actions CI will run automatically when the "Run CICD" label is added to the PR. To re-run CI remove and add the label again. To run CI on an untrusted fork, a NeMo user with write access must first click "Approve and run".
Before your PR is "Ready for review"
Pre checks:
- [x] Make sure you read and followed Contributor guidelines
- [ ] Did you write any new necessary tests?
- [ ] Did you add or update any necessary documentation?
- [x] Does the PR affect components that are optional to install? (Ex: Numba, Pynini, Apex etc)
- [ ] Reviewer: Does the PR have correct import guards for all optional libraries?
PR Type:
- [x] New Feature
- [ ] Bugfix
- [ ] Documentation
If you haven't finished some of the above items you can still open "Draft" PR.
Who can review?
Anyone in the community is free to review the PR once the checks have passed. Contributor guidelines contains specific people who can review PRs to various areas.
Additional Information
Loss curves between Megatron and Nemo for Llama-3.1 8B->4B
[🤖]: Hi @AAnoosheh 👋,
We wanted to let you know that a CICD pipeline for this PR just finished successfully.
So it might be time to merge this PR or get some approvals.
Due to a major CI change, merges are currently handled by the automation team.
We will reach out to you quickly to merge this PR, but you can always reach us with the following handles:
//cc @chtruong814 @ko3n1g @pablo-garay @thomasdhc
@AAnoosheh add the additional loss curves.
Approved to merge. TODO: check individual losses match after logging gets fixed in nemo.
[🤖]: Hi @AAnoosheh 👋,
We wanted to let you know that a CICD pipeline for this PR just finished successfully.
So it might be time to merge this PR or get some approvals.
//cc @chtruong814 @ko3n1g @pablo-garay @thomasdhc
The failed ASR test should be optional. I'm going to go ahead and merge this.