Skip to content

fix convert_llama_hf_to_nemo.py llama31 argument#11870

Closed
j40903272 wants to merge 1 commit intoNVIDIA-NeMo:mainfrom
j40903272:patch-1
Closed

fix convert_llama_hf_to_nemo.py llama31 argument#11870
j40903272 wants to merge 1 commit intoNVIDIA-NeMo:mainfrom
j40903272:patch-1

Conversation

@j40903272
Copy link
Copy Markdown

What does this PR do ?

Fix conversion script arguments. The original script using type=bool convert empty strings to False and non-empty strings to True. Might not be an ideal way of using it.

Collection: NLP

Changelog

  • Fix convert_llama_hf_to_nemo script --llama31 arguments.

Usage

$ scripts/checkpoint_converters/convert_llama_hf_to_nemo.py --llama31  # when it is llama31
$ scripts/checkpoint_converters/convert_llama_hf_to_nemo.py                  # when it is not llama31

Signed-off-by: YunDa Tsai <f08946007@csie.ntu.edu.tw>
@github-actions
Copy link
Copy Markdown
Contributor

beep boop 🤖: 🙏 The following files have warnings. In case you are familiar with these, please try helping us to improve the code base.


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

************* Module convert_llama_hf_to_nemo
scripts/checkpoint_converters/convert_llama_hf_to_nemo.py:63:0: C0301: Line too long (218/119) (line-too-long)
scripts/checkpoint_converters/convert_llama_hf_to_nemo.py:46:0: C0116: Missing function or method docstring (missing-function-docstring)
scripts/checkpoint_converters/convert_llama_hf_to_nemo.py:75:0: C0116: Missing function or method docstring (missing-function-docstring)
scripts/checkpoint_converters/convert_llama_hf_to_nemo.py:129:0: C0116: Missing function or method docstring (missing-function-docstring)

-----------------------------------
Your code has been rated at 9.80/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!

@j40903272 j40903272 marked this pull request as draft January 16, 2025 12:32
@j40903272 j40903272 marked this pull request as ready for review January 16, 2025 12:33
@j40903272
Copy link
Copy Markdown
Author

@MaximumEntropy, @ericharper, @ekmb, @yzhang123, @VahidooX, @vladgets, @okuchaiev

Can anyone help with the review?

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 5, 2025

This PR is stale because it has been open for 14 days with no activity. Remove stale label or comment or update or this will be closed in 7 days.

@github-actions github-actions Bot added the stale label Feb 5, 2025
@github-actions
Copy link
Copy Markdown
Contributor

This PR was closed because it has been inactive for 7 days since being marked as stale.

@github-actions github-actions Bot closed this Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant