System Info
This is relevant to Transformers because the failure is triggered by the Transformers v5 loading path itself.
In v5, from_pretrained() initializes models on the meta device before loading weights. Old OpenGVLab/InternVL2-* remote-code checkpoints perform real-tensor operations during model construction (for example calling .item()), so they fail under the v5 loading mechanism.
From a downstream user's perspective, this happens directly inside AutoModel.from_pretrained(..., trust_remote_code=True), so it is effectively a Transformers compatibility / migration issue, not only a checkpoint-local issue.
This currently blocks vLLM's Transformers v5 upgrade work because the HF reference model for OpenGVLab/InternVL2-1B/2B cannot be instantiated:
Who can help?
No response
Information
Tasks
Reproduction
vllm-project/vllm#38425
Expected behavior
vllm-project/vllm#38425
System Info
This is relevant to Transformers because the failure is triggered by the Transformers v5 loading path itself.
In v5,
from_pretrained()initializes models on themetadevice before loading weights. OldOpenGVLab/InternVL2-*remote-code checkpoints perform real-tensor operations during model construction (for example calling.item()), so they fail under the v5 loading mechanism.From a downstream user's perspective, this happens directly inside
AutoModel.from_pretrained(..., trust_remote_code=True), so it is effectively a Transformers compatibility / migration issue, not only a checkpoint-local issue.This currently blocks vLLM's Transformers v5 upgrade work because the HF reference model for
OpenGVLab/InternVL2-1B/2Bcannot be instantiated:Who can help?
No response
Information
Tasks
examplesfolder (such as GLUE/SQuAD, ...)Reproduction
vllm-project/vllm#38425
Expected behavior
vllm-project/vllm#38425