Prhub

#50313 Revert "[Misc][Minimax-M3]add default video_processor (#50092)"

原始 PR 作者 njhill 合并时间 2026-07-30 04:46 文件变更 2 提交数 1 评论 0 代码增减 +7 / -44

执行摘要

回滚 Minimax-M3 默认视频处理器提交

PR #50092 的提交导致 CI 测试失败,报错 AttributeError: '_OpNamespace' '_C' object has no attribute 'rms_norm_static_fp8_quant',因此需要紧急回滚以确保主分支稳定性。

建议精读以了解回滚原因及上游 PR 的问题模式。后续如需重新引入该功能,应确保 torch.ops._C.rms_norm_static_fp8_quant 算子存在或增加兼容性检查。

讨论亮点

该 PR 仅回滚操作,无实质 review 讨论。审核人 AndreasKaratzas 和 mgoin 均批准。

实现拆解

  1. vllm/models/minimax_m3/common/mm_preprocess.py:回滚 MiniMaxM3VideoBackend 类,移除新增的 load_bytes 方法及其导入依赖(Any, Literal, numpy.typing),将 compute_frames_index_to_sample 的最后帧索引从 total_frames 改回 total_frames - 1,并简化注册装饰器参数。
  2. tests/multimodal/test_video.py:移除对 MiniMaxM3VideoBackend 的导入和对应的测试参数化条目(MiniMaxAI/MiniMax-M3)。
文件 模块 状态 重要度
vllm/models/minimax_m3/common/mm_preprocess.py 模型层 modified 7.01
tests/multimodal/test_video.py 视频 modified 3.84

关键符号

load_bytes compute_frames_index_to_sample

关键源码片段

vllm/models/minimax_m3/common/mm_preprocess.py data-contract

核心变更文件,回滚了 `MiniMaxM3VideoBackend.load_bytes` 方法及注册装饰器,简化了 backend 注册。

# 回滚后的 MiniMaxM3VideoBackend:移除 load_bytes 方法,简化注册
@VIDEO_LOADER_REGISTRY.register("minimax_m3_vl")
class MiniMaxM3VideoBackend(VideoBackend):
    @classmethod
    def compute_frames_index_to_sample(
        cls,
        source: VideoSourceMetadata,
        target: VideoTargetMetadata,
        **kwargs,
    ) -> list[int]:
        total_frames = source.total_frames_num
        video_fps = source.original_fps
        fps = target.fps
        if total_frames <= 0 or video_fps <= 0 or fps <= 0:
            return [0] if total_frames > 0 else []
        # ... 中间帧采样逻辑不变 ...
        # 注意:原 PR 中 last_frame_idx = total_frames,回滚后恢复为 total_frames - 1
        last_frame_idx = total_frames - 1
        last_ts = last_frame_idx / video_fps
        if indices and indices[-1] != last_frame_idx and last_ts - prev_kept_ts > eps:
            indices.append(last_frame_idx)
        if not indices:
            indices = [0]
        return indices

评论区精华

没有提炼出高价值讨论线程

当前评论区没有形成足够清晰的争议点或结论,后续有更多讨论时会体现在这里。

风险与影响

无新增风险,回滚操作将仓库恢复至 PR #50092 合并前的状态,消除了 CI 故障。但 Minimax-M3 的视频处理功能暂时降级,依赖该功能的用户可能受影响。

影响范围:仅涉及 Minimax-M3 模型,其他模型不受影响。影响程度:低,因为原功能未经过充分测试即引入,回滚后回归稳定状态。

回滚操作 依赖缺失

关联 Issue

未识别关联 Issue

当前没有检测到明确关联的 Issue 链接,后续同步到相关引用后会出现在这里。

完整报告

参与讨论