Skip to content

Eval bug: MiMo-V2.5-Pro fails to load with hparam error #28831

Closed

Description

@DocShotgun

Name and Version

llama-server 790cf51, however git bisect points to 9d81721 as the first bad commit.

Operating systems

Linux

GGML backends

CUDA

Hardware

1x RTX Pro 6000
2x 5th gen Xeon Platinum

Models

https://huggingface.co/AesSedai/MiMo-V2.5-Pro-GGUF/tree/main/Q4_K_M

Problem description & steps to reproduce

When attempting to load MiMo-V2.5-Pro (specific quant linked above) via llama-server, it fails immediately when trying to read the model hyperparameters.

First Bad Commit

git bisect points to 9d81721 as the first bad commit.

Relevant log output

Logs
0.00.531.350 E llama_model_load: error loading model: error loading model hyperparameters: key mimo2.attention.sliding_window_pattern has wrong array length; expected 70, got 73
0.00.531.355 E llama_model_load_from_file_impl: failed to load model
0.00.531.358 E cmn  common_init_: failed to load model '/mnt/data/models/GGUF/MiMo-V2.5-Pro-Q4_K_M/MiMo-V2.5-Pro-Q4_K_M-00001-of-00015.gguf'
0.00.531.361 E srv    load_model: failed to load model, '/mnt/data/models/GGUF/MiMo-V2.5-Pro-Q4_K_M/MiMo-V2.5-Pro-Q4_K_M-00001-of-00015.gguf'
0.00.531.363 I srv    operator(): operator(): cleaning up before exit...
0.00.557.111 E srv  llama_server: exiting due to model loading error

Activity

  1. DengZhiyuan-math commented on Sep 13, 2026

    @DengZhiyuan-math

    I’d like to work on this. The reported regression appears to come from #28159 moving the NextN count load earlier: hparams.n_layer() now excludes the MTP layers when MiMo reads its SWA pattern, while the converter writes one entry per block, including MTP blocks.
    I propose changing that read in src/models/mimo2.cpp to use hparams.n_layer_all, matching the Step35 adjustment in the same commit.
    I’ll add a regression in tests/test-llama-archs.cpp with two trunk layers, three NextN layers, and a five-entry SWA pattern, while retaining the no-NextN case. The synthetic case will explicitly enable MTP tensor loading. Validation will cover the reported length mismatch, layer counts, and ordinary decoding; I haven’t run it yet.
    Is anyone already working on this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions