fix: make Nemotron-H import error adaption on Megatron-Core 0.16.1 - #171
Conversation
|
Thanks for the fix! Instead of guarding the import at the init.py level, would it be cleaner to wrap the relevant imports inside nemotron_h.py itself with a try/except ImportError? This way the file is self-contained — it won't break on import regardless of where it's imported from, and we don't need to maintain a whitelist in init.py every time a new model has optional dependencies. |
|
Thanks for the suggestion — addressed in 04e21c5. The HybridModel availability check now lives in |
Make Nemotron-H registration conditional when the installed Megatron-Core does not provide megatron.core.models.hybrid. On Ascend A3 with Megatron-Core 0.16.1 and USE_MCORE_GDN=0, the training initialization import passed and Nemotron-H was correctly skipped.