mirror of
https://github.com/vllm-project/vllm.git
synced 2025-10-20 14:53:52 +08:00
[bugfix] Qwen3-VL fix video incorrect timestamp calculations while do_sample_frames=True (#27104)
Co-authored-by: 松灵 <wpf272043@alibaba-inc.com>
This commit is contained in:
@ -735,9 +735,9 @@ class Qwen3VLProcessingInfo(Qwen2VLProcessingInfo):
|
||||
if do_sample_frames:
|
||||
# here video_fps is the fps of the sampled video, and
|
||||
# metadata["fps"] refers to the fps of the original video.
|
||||
video_fps = sampled_fps if sampled_fps else video_processor.fps
|
||||
sampled_fps = sampled_fps if sampled_fps else video_processor.fps
|
||||
total_num_frames = metadata["total_num_frames"]
|
||||
num_frames = int(total_num_frames / metadata["fps"] * video_fps)
|
||||
num_frames = int(total_num_frames / metadata["fps"] * sampled_fps)
|
||||
num_frames = min(
|
||||
min(
|
||||
max(num_frames, video_processor.min_frames),
|
||||
|
Reference in New Issue
Block a user