From ba51f150e56b3d82dfe37e9da3dc045661bf0881 Mon Sep 17 00:00:00 2001 From: "Liu, Kaixuan" Date: Tue, 28 Apr 2026 07:36:29 +0000 Subject: [PATCH 1/2] update revision for Phi-4 model to make it run w/o remote code Signed-off-by: Liu, Kaixuan --- tests/models/phi4_multimodal/test_modeling_phi4_multimodal.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/models/phi4_multimodal/test_modeling_phi4_multimodal.py b/tests/models/phi4_multimodal/test_modeling_phi4_multimodal.py index 6274f26ea605..e93ae070fa90 100644 --- a/tests/models/phi4_multimodal/test_modeling_phi4_multimodal.py +++ b/tests/models/phi4_multimodal/test_modeling_phi4_multimodal.py @@ -276,13 +276,13 @@ def test_flex_attention_with_grads(self): @slow class Phi4MultimodalIntegrationTest(unittest.TestCase): checkpoint_path = "microsoft/Phi-4-multimodal-instruct" - revision = "refs/pr/70" + revision = "refs/pr/94" image_url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/transformers/tasks/australia.jpg" audio_url = "https://huggingface.co/datasets/raushan-testing-hf/audio-test/resolve/main/f2641_0_throatclearing.wav" def setUp(self): # Currently, the Phi-4 checkpoint on the hub is not working with the latest Phi-4 code, so the slow integration tests - # won't pass without using the correct revision (refs/pr/70) + # won't pass without using the correct revision (refs/pr/94) self.processor = AutoProcessor.from_pretrained(self.checkpoint_path, revision=self.revision) self.generation_config = GenerationConfig(max_new_tokens=20, do_sample=False) self.user_token = "<|user|>" From 11747790897744b727a39cf446f30a238cd95f74 Mon Sep 17 00:00:00 2001 From: "Liu, Kaixuan" Date: Tue, 28 Apr 2026 07:51:48 +0000 Subject: [PATCH 2/2] update Signed-off-by: Liu, Kaixuan --- tests/models/phi4_multimodal/test_processing_phi4_multimodal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/models/phi4_multimodal/test_processing_phi4_multimodal.py b/tests/models/phi4_multimodal/test_processing_phi4_multimodal.py index 343768c0bb5f..a8c3f0db4db2 100644 --- a/tests/models/phi4_multimodal/test_processing_phi4_multimodal.py +++ b/tests/models/phi4_multimodal/test_processing_phi4_multimodal.py @@ -32,7 +32,7 @@ class Phi4MultimodalProcessorTest(ProcessorTesterMixin, unittest.TestCase): processor_class = Phi4MultimodalProcessor checkpoint_path = "microsoft/Phi-4-multimodal-instruct" - revision = "refs/pr/70" + revision = "refs/pr/94" text_input_name = "input_ids" images_input_name = "image_pixel_values" audio_input_name = "audio_input_features"