Multimodal: model_provider() got an unexpected keyword argument 'config'
- Dominant language
- Python
- Stars
- 17.9k
- Forks
- 4.5k
- Avg merge
- 4d 6h
- Merged PRs (30d)
- 271
Description
**Describe the bug**
Running the multimodal pretrain_mistral_clip.sh, got an error
```
[after megatron is initialized] datetime: 2026-02-18 01:03:46.491419
Failed to inspect checkpoint in ./output/mcore-llava-mistral-7b-instruct-clip336-pretraining/checkpoints: _load_base_checkpoint() missing 1 required positional argument: 'args'
[rank0]: Traceback (most recent call last):
[rank0]: File "/workspace/megatron-lm/examples/multimodal/train.py", line 384, in
[rank0]: pretrain(
[rank0]: File "/workspace/megatron-lm/megatron/training/training.py", line 945, in pretrain
[rank0]: model, optimizer, opt_param_scheduler = setup_model_and_optimizer(
[rank0]: ^^^^^^^^^^^^^^^^^^^^^^^^^^
[rank0]: File "/workspace/megatron-lm/megatron/training/training.py", line 1515, in setup_model_and_optimizer
[rank0]: model = get_model(model_provider_func, model_type, wrap_with_ddp=wrap_with_ddp)
[rank0]: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[rank0]: File "/workspace/megatron-lm/megatron/training/training.py", line 1288, in get_model
[rank0]: model = build_model()
[rank0]: ^^^^^^^^^^^^^
[rank0]: File "/workspace/megatron-lm/megatron/training/training.py", line 1274, in build_model
[rank0]: model = model_provider_func(
[rank0]: ^^^^^^^^^^^^^^^^^^^^
[rank0]: TypeError: model_provider() got an unexpected keyword argument 'config'
```
A clear and concise description of what the bug is. Tag the [@mcore-oncall](https://github.com/orgs/NVIDIA/teams/mcore-oncall)
to get oncall's attention to this issue.
**Steps/Code to reproduce bug**
Please list *minimal* steps or code snippet for us to be able to reproduce the bug.
A helpful guide on on how to craft a minimal bug report http://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports.
**Expected behavior**
A clear and concise description of what you expected to happen.
**Additional context**
Add any other context about the problem here.
Contributor guide
Assessment
This issue has not been assessed yet.