diff --git a/vllm_omni/model_executor/models/hunyuan_image3/hunyuan_image3.py b/vllm_omni/model_executor/models/hunyuan_image3/hunyuan_image3.py index 4596d1145..b68a6fc3a 100644 --- a/vllm_omni/model_executor/models/hunyuan_image3/hunyuan_image3.py +++ b/vllm_omni/model_executor/models/hunyuan_image3/hunyuan_image3.py @@ -96,7 +96,16 @@ from vllm_omni.model_executor.models.hunyuan_image3.siglip2 import LightProjecto logger = init_logger(__name__) -@support_torch_compile +@support_torch_compile( + dynamic_arg_dims={ + "input_ids": 0, + # positions is (3, num_tokens) for mRoPE, so the token dimension is + # the last dimension rather than dim 0. + "positions": -1, + "intermediate_tensors": 0, + "inputs_embeds": 0, + } +) class HunyuanModel(HunYuanModel): def _split_qkv_weight(self, qkv: torch.Tensor): num_attention_heads = self.config.num_attention_heads