Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make some configs optional #12465

Merged
merged 4 commits into from
Mar 4, 2025

Conversation

maanug-nv
Copy link
Collaborator

Important

The Update branch button 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: [Note which collection this PR will affect]

Changelog

  • Add specific line by line info of high level changes in this PR.

Usage

  • You can potentially add a usage example below
# Add a code snippet demonstrating how to use this 

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:

  • Make sure you read and followed Contributor guidelines
  • Did you write any new necessary tests?
  • Did you add or update any necessary documentation?
  • 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:

  • 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

  • Related to # (issue)

Signed-off-by: Maanu Grover <[email protected]>
Signed-off-by: Maanu Grover <[email protected]>
Signed-off-by: Maanu Grover <[email protected]>
Copy link
Contributor

github-actions bot commented Mar 4, 2025

beep boop 🤖: 🚨 The following files must be fixed before merge!


Your code was analyzed with PyLint. The following annotations have been identified:

************* Module nemo.tron.config
nemo/tron/config.py:131:0: C0301: Line too long (153/119) (line-too-long)
nemo/tron/config.py:134:0: C0301: Line too long (262/119) (line-too-long)
nemo/tron/config.py:137:0: C0301: Line too long (455/119) (line-too-long)
nemo/tron/config.py:140:0: C0301: Line too long (364/119) (line-too-long)
nemo/tron/config.py:143:0: C0301: Line too long (133/119) (line-too-long)
nemo/tron/config.py:152:0: C0301: Line too long (135/119) (line-too-long)
nemo/tron/config.py:167:0: C0301: Line too long (376/119) (line-too-long)
nemo/tron/config.py:170:0: C0301: Line too long (158/119) (line-too-long)
nemo/tron/config.py:173:0: C0301: Line too long (123/119) (line-too-long)
nemo/tron/config.py:198:0: C0301: Line too long (142/119) (line-too-long)
nemo/tron/config.py:204:0: C0301: Line too long (196/119) (line-too-long)
nemo/tron/config.py:207:0: C0301: Line too long (200/119) (line-too-long)
nemo/tron/config.py:210:0: C0301: Line too long (234/119) (line-too-long)
nemo/tron/config.py:213:0: C0301: Line too long (147/119) (line-too-long)
nemo/tron/config.py:221:0: C0301: Line too long (278/119) (line-too-long)
nemo/tron/config.py:256:0: C0301: Line too long (157/119) (line-too-long)
nemo/tron/config.py:259:0: C0301: Line too long (483/119) (line-too-long)
nemo/tron/config.py:262:0: C0301: Line too long (170/119) (line-too-long)
nemo/tron/config.py:271:0: C0301: Line too long (126/119) (line-too-long)
nemo/tron/config.py:329:0: C0301: Line too long (250/119) (line-too-long)
nemo/tron/config.py:332:0: C0301: Line too long (207/119) (line-too-long)
nemo/tron/config.py:388:0: C0301: Line too long (378/119) (line-too-long)
nemo/tron/config.py:400:0: C0301: Line too long (154/119) (line-too-long)
nemo/tron/config.py:412:0: C0301: Line too long (120/119) (line-too-long)
nemo/tron/config.py:415:0: C0301: Line too long (210/119) (line-too-long)
nemo/tron/config.py:427:0: C0301: Line too long (223/119) (line-too-long)
nemo/tron/config.py:430:0: C0301: Line too long (225/119) (line-too-long)
nemo/tron/config.py:439:0: C0301: Line too long (170/119) (line-too-long)
nemo/tron/config.py:451:0: C0301: Line too long (224/119) (line-too-long)
nemo/tron/config.py:457:0: C0301: Line too long (268/119) (line-too-long)
nemo/tron/config.py:469:0: C0301: Line too long (128/119) (line-too-long)
nemo/tron/config.py:539:0: C0301: Line too long (124/119) (line-too-long)
nemo/tron/config.py:30:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:46:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:60:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:108:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:127:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:188:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:217:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:243:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:305:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:360:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:464:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:485:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:504:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/config.py:22:0: W0611: Unused ModelType imported from megatron.core.transformer.enums (unused-import)
************* Module nemo.tron.setup
nemo/tron/setup.py:47:0: C0115: Missing class docstring (missing-class-docstring)
nemo/tron/setup.py:58:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/setup.py:40:4: W0611: Unused TorchFullyShardedDataParallel imported from megatron.core.distributed (unused-import)
************* Module nemo.tron.train
nemo/tron/train.py:246:0: C0301: Line too long (121/119) (line-too-long)
nemo/tron/train.py:73:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/train.py:574:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/train.py:580:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/train.py:628:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/train.py:660:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/train.py:39:0: W0611: Unused CheckpointConfig imported from nemo.tron.config (unused-import)
************* Module nemo.tron.utils.train_utils
nemo/tron/utils/train_utils.py:398:0: C0301: Line too long (126/119) (line-too-long)
nemo/tron/utils/train_utils.py:47:0: C0116: Missing function or method docstring (missing-function-docstring)
nemo/tron/utils/train_utils.py:184:0: C0116: Missing function or method docstring (missing-function-docstring)

-----------------------------------
Your code has been rated at 9.43/10

Mitigation guide:

  • Add sensible and useful docstrings to functions and methods
  • For trivial methods like getter/setters, consider adding # pylint: disable=C0116 inside the function itself
  • To disable multiple functions/methods at once, put a # pylint: disable=C0116 before the first and a # pylint: enable=C0116 after the last.

By applying these rules, we reduce the occurance of this message in future.

Thank you for improving NeMo's documentation!

@maanug-nv maanug-nv requested a review from hemildesai March 4, 2025 01:36
@maanug-nv maanug-nv merged commit ee86679 into mlm-pretrain-loop Mar 4, 2025
13 of 14 checks passed
@maanug-nv maanug-nv deleted the maanug/container-optional-configs branch March 4, 2025 19:13
hemildesai pushed a commit that referenced this pull request Mar 20, 2025
* make ft, straggler, profiling, optional

Signed-off-by: Maanu Grover <[email protected]>

* build tokenizer in setup

Signed-off-by: Maanu Grover <[email protected]>

* fix for profiling

Signed-off-by: Maanu Grover <[email protected]>

* fix for tokenizer

Signed-off-by: Maanu Grover <[email protected]>

---------

Signed-off-by: Maanu Grover <[email protected]>
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.

3 participants