from typing import List, Optional, Tuple, Type, overload import pytest import transformers from transformers import AutoConfig, AutoModelForVision2Seq, AutoTokenizer from aphrodite.common.sequence import SampleLogprobs from aphrodite.multimodal.utils import (rescale_video_size, resize_video, sample_frames_from_video) from ..conftest import VIDEO_ASSETS, AphroditeRunner, HfRunner, _VideoAssets from .utils import check_logprobs_close pytestmark = pytest.mark.vlm _PREFACE = ( "A chat between a curious human and an artificial intelligence assistant. " "The assistant gives helpful, detailed, and polite answers to the human's " "questions." ) HF_VIDEO_PROMPTS = VIDEO_ASSETS.prompts( { "sample_demo_1": f"{_PREFACE}USER: