Skip to content

[Other] support video_fps args for video bench#7077

Open
Wanglongzhi2001 wants to merge 1 commit intoPaddlePaddle:developfrom
Wanglongzhi2001:fix_mm_kwargs
Open

[Other] support video_fps args for video bench#7077
Wanglongzhi2001 wants to merge 1 commit intoPaddlePaddle:developfrom
Wanglongzhi2001:fix_mm_kwargs

Conversation

@Wanglongzhi2001
Copy link
Copy Markdown
Collaborator

Motivation

💡 If this PR is a Cherry Pick, the PR title needs to follow the format by adding the [Cherry-Pick] label at the very beginning and appending the original PR ID at the end. For example, [Cherry-Pick][CI] Add check trigger and logic(#5191)

💡 如若此PR是Cherry Pick,PR标题需遵循格式,在最开始加上[Cherry-Pick]标签,以及最后面加上原PR ID,例如[Cherry-Pick][CI] Add check trigger and logic(#5191)

Modifications

Usage or Command

Accuracy Tests

Checklist

  • Add at least a tag in the PR title.
    • Tag list: [[FDConfig],[APIServer],[Engine], [Scheduler], [PD Disaggregation], [Executor], [Graph Optimization], [Speculative Decoding], [RL], [Models], [Quantization], [Loader], [OP], [KVCache], [DataProcessor], [BugFix], [Docs], [CI], [Optimization], [Feature], [Benchmark], [Others], [XPU], [HPU], [GCU], [DCU], [Iluvatar], [Metax]]
    • You can add new tags based on the PR content, but the semantics must be clear.
  • Format your code, run pre-commit before commit.
  • Add unit tests. Please write the reason in this PR if no unit tests.
  • Provide accuracy results.
  • If the current PR is submitting to the release branch, make sure the PR has been submitted to the develop branch, then cherry-pick it to the release branch with the [Cherry-Pick] PR tag.

Copilot AI review requested due to automatic review settings March 30, 2026 07:00
@paddle-bot
Copy link
Copy Markdown

paddle-bot bot commented Mar 30, 2026

Thanks for your contribution!

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

该 PR 旨在为 OpenAI 协议的 completions / chat.completions 请求增加一个临时参数 video_fps,以支持视频理解相关 benchmark 在请求侧传入抽帧 FPS 信息。

Changes:

  • CompletionRequest 中新增可选字段 video_fps
  • ChatCompletionRequest 中新增可选字段 video_fps

Comment on lines +551 to +553
# NOTE(Wanglongzhi2001): temporary parameter for video understanding benchmark
video_fps: Optional[float] = None

Copy link

Copilot AI Mar 30, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里新增的 video_fps 目前只会被透传进 to_dict_for_infer() 的 req_dict,但在仓库内的输入处理链路中未找到任何地方读取/应用该字段(搜索仅在 protocol.py 中出现)。这会导致基准测试传入 video_fps 也不会影响实际抽帧逻辑。建议在预处理阶段将其映射到视频 item 的 fps(如 messages/multimodal_data 的 video part),或改为复用现有的 mm_processor_kwargs.video_fps 机制并在处理器侧消费该参数。

Copilot uses AI. Check for mistakes.
Comment on lines +740 to +742
# NOTE(Wanglongzhi2001): temporary parameter for video understanding benchmark
video_fps: Optional[float] = None

Copy link

Copilot AI Mar 30, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

新增请求字段后建议补充单测覆盖:例如验证当用户传入 video_fps 时,CompletionRequest/ChatCompletionRequest.to_dict_for_infer() 的输出会包含该字段(且为预期类型/取值)。仓库已有 openai protocol 相关测试(tests/entrypoints/openai/*),增加回归测试能避免后续重构导致该临时参数被悄然丢弃。

Copilot uses AI. Check for mistakes.
Comment on lines +551 to +552
# NOTE(Wanglongzhi2001): temporary parameter for video understanding benchmark
video_fps: Optional[float] = None
Copy link

Copilot AI Mar 30, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

当前 PR 标题使用了 [Other],但仓库 PR 模板的 tag list 中是 [Others](见 .github/pull_request_template.md 的 Checklist)。建议把标题 tag 调整为已有的 [Others] 或新增语义更明确的 tag,以满足仓库约定。

Copilot uses AI. Check for mistakes.
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Mar 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (develop@10c59f7). Learn more about missing BASE report.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop    #7077   +/-   ##
==========================================
  Coverage           ?   74.07%           
==========================================
  Files              ?      401           
  Lines              ?    56575           
  Branches           ?     8942           
==========================================
  Hits               ?    41909           
  Misses             ?    11685           
  Partials           ?     2981           
Flag Coverage Δ
GPU 74.07% <100.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants