Skip to content

export checkpoint error: too many values to unpack (expected 2) #1996

@wenkaixiansheng

Description

@wenkaixiansheng

When I tried to convert the Megatron checkpoint such as Qwen3-8B, 32B, and 30B to Huggingface using megatron-bridge, I encountered the following error. I am using the latest commit of the main branch of Megatron-LM, and in this version, converting from Huggingface to Megatron is correct.

"
Traceback (most recent call last):
File "/usr/local/lib/python3.12/dist-packages/megatron/bridge/models/decorators/torchrun.py", line 37, in wrapper
return_value = recorded_fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/dist-packages/torch/distributed/elastic/multiprocessing/errors/init.py", line 357, in wrapper
return f(*args, **kwargs)
^^^^^^^^^^^^^^^^^^
File "/mnt/cephfs/xianda/slime-internal/tools/megatron-bridge-beta/convert_torch_dist_to_hf_multi_GPU.py", line 110, in main
for name, param in bridge.export_hf_weights(megatron_model, show_progress=False):
^^^^^^^^^^^
ValueError: too many values to unpack (expected 2)
"

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions