From 6eabc6cb0e022a3f57fbf115ce53dc8bcba66840 Mon Sep 17 00:00:00 2001 From: Cyrus Leung Date: Thu, 27 Jun 2024 14:20:01 +0800 Subject: [PATCH] [Doc] Add note about context length in Phi-3-Vision example (#5887) --- examples/phi3v_example.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/examples/phi3v_example.py b/examples/phi3v_example.py index 4f37c47ddca87..c068b9a9844e4 100644 --- a/examples/phi3v_example.py +++ b/examples/phi3v_example.py @@ -9,6 +9,9 @@ from vllm.multimodal.image import ImagePixelData def run_phi3v(): model_path = "microsoft/Phi-3-vision-128k-instruct" + + # Note: The model has 128k context length by default which may cause OOM + # If that's the case, override `max_model_len` with a smaller value via args llm = LLM( model=model_path, trust_remote_code=True, @@ -16,7 +19,6 @@ def run_phi3v(): image_token_id=32044, image_input_shape="1,3,1008,1344", image_feature_size=1921, - disable_image_processor=False, ) image = Image.open("images/cherry_blossom.jpg")