Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add: num_additional_image_tokens to models #35052

Merged
merged 14 commits into from
Jan 8, 2025
Merged
Prev Previous commit
Next Next commit
Fix: adjust num_image_tokens calculation in VideoLlavaProcessor
jp1924 committed Dec 9, 2024
commit 114283b8109644a7395f889f3ac4887c12522986
Original file line number Diff line number Diff line change
@@ -187,7 +187,7 @@ def __call__(
) + self.num_additional_image_tokens
num_video_tokens = num_image_tokens * num_frames
if self.vision_feature_select_strategy == "default":
num_image_tokens -= self.num_additional_image_tokens
num_image_tokens -= 1

prompt_strings = []
for sample in text: