[Temp fix] Disable torch.compile for Qwen2.5 VL's VisionBlock temporarily. (#27760)

Signed-off-by: Chenheli Hua <huachenheli@outlook.com>
Signed-off-by: Roger Wang <hey@rogerw.io>
Co-authored-by: Roger Wang <hey@rogerw.io>
This commit is contained in:
Chenheli Hua 2025-10-29 16:17:48 -07:00 committed by GitHub
parent b5d90f7400
commit 48eb8eba58
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -460,15 +460,17 @@ class Qwen2_5_VisionAttention(nn.Module):
return output
@support_torch_compile(
dynamic_arg_dims={
"x": 0,
"cu_seqlens": 0,
"rotary_pos_emb": 0,
"seqlens": 0,
},
mark_unbacked_dims={"seqlens": 0},
)
# (FIXME): Enable this after dynamic slicing is fixed
# See https://github.com/vllm-project/vllm/pull/27760
# @support_torch_compile(
# dynamic_arg_dims={
# "x": 0,
# "cu_seqlens": 0,
# "rotary_pos_emb": 0,
# "seqlens": 0,
# },
# mark_unbacked_dims={"seqlens": 0},
# )
class Qwen2_5_VisionBlock(nn.Module):
def __init__(
self,