🚨Default to fast image processors for all models
What does this PR do?
Following the trial testing with Qwen_VL image processors, this extends defaulting to fast image processors even for checkpoints saved with a slow one to all models.
Also made sure that all processors use AutoImageProcessor to instantiate their image_processor_class. On that point, defining default subclass in processors feels a bit redundant, as we basically already have that in auto classes. It would be nice to get rid of this for v5, wdyt @molbap @zucchini-nlp @ArthurZucker ? I'll open a PR for that too.
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.
LGTM. Just wondering about some models where we had no lancsoz resampling. Do we get the closest resampling in those cases and are the diffs small enough?
Good point for the lanczos sampling, I might add an exception for these, as the diffs are not close enough imo
run-slow: aria, clip, efficientloftr, emu3, fuyu, idefics2, idefics3, janus, kosmos2, kosmos2_5, layoutxlm, lightglue, llava_onevision, mllama, oneformer
This comment contains run-slow, running the specified jobs:
models: ["models/aria", "models/clip", "models/efficientloftr", "models/emu3", "models/fuyu", "models/idefics2", "models/idefics3", "models/janus", "models/kosmos2", "models/kosmos2_5", "models/layoutxlm", "models/lightglue", "models/llava_onevision", "models/mllama", "models/oneformer"] quantizations: []
CI Results
Model CI Report
❌ Failed tests
-
clip: tests/models/clip/test_modeling_clip.py::CLIPModelIntegrationTest::test_inference_interpolate_pos_encoding
-
janus: tests/models/janus/test_modeling_janus.py::JanusIntegrationTest::test_model_generate_images
-
kosmos2_5: tests/models/kosmos2_5/test_modeling_kosmos2_5.py::Kosmos2_5ModelIntegrationTest::test_eager
-
oneformer: tests/models/oneformer/test_modeling_oneformer.py::OneFormerModelIntegrationTest::test_inference_no_head tests/models/oneformer/test_modeling_oneformer.py::OneFormerModelIntegrationTest::test_inference_universal_segmentation_head
[For maintainers] Suggested jobs to run (before merge)
run-slow: altclip, aria, auto, aya_vision, chinese_clip, clip, clipseg, convnext, convnextv2, cvt, dinov2, dinov2_with_registers, efficientloftr, fuyu, idefics2, idefics3
I have pushed the updates. The following remaining failures needs some fix (not about expected output mismatching)
(if you want to read the log, you can go here and select ⚙️ icon and click View raw logs on the top left side)
This one
RUN_SLOW=1 python3 -m pytest -v tests/models/janus/test_modeling_janus.py::JanusIntegrationTest::test_model_generate_images - ValueError: Only returning PyTorch tensors is currently supported.
plus the following
{
"clipseg": {
"single-gpu": [
{
"test": "tests/models/clipseg/test_modeling_clipseg.py::CLIPSegModelIntegrationTest::test_inference_image_segmentation",
"commit": "07a50c395552a28582c2746e06318e8f2e1bf059",
"status": "git bisect found the bad commit.",
"pr_number": null,
"author": "ydshieh",
"merged_by": null,
"parent": "377a8ee73f210476c4efb15170d0c32ad3b2c653"
}
]
},
"flava": {
"single-gpu": [
{
"test": "tests/models/flava/test_modeling_flava.py::FlavaForPreTrainingIntegrationTest::test_inference",
"commit": "07a50c395552a28582c2746e06318e8f2e1bf059",
"status": "git bisect found the bad commit.",
"pr_number": null,
"author": "ydshieh",
"merged_by": null,
"parent": "377a8ee73f210476c4efb15170d0c32ad3b2c653"
}
]
},
"gemma3": {
"single-gpu": [
{
"test": "tests/models/gemma3/test_modeling_gemma3.py::Gemma3IntegrationTest::test_model_4b_batch_crops",
"commit": "07a50c395552a28582c2746e06318e8f2e1bf059",
"status": "git bisect found the bad commit.",
"pr_number": null,
"author": "ydshieh",
"merged_by": null,
"parent": "377a8ee73f210476c4efb15170d0c32ad3b2c653"
},
{
"test": "tests/models/gemma3/test_modeling_gemma3.py::Gemma3IntegrationTest::test_model_4b_crops",
"commit": "07a50c395552a28582c2746e06318e8f2e1bf059",
"status": "git bisect found the bad commit.",
"pr_number": null,
"author": "ydshieh",
"merged_by": null,
"parent": "377a8ee73f210476c4efb15170d0c32ad3b2c653"
}
]
},
"yolos": {
"single-gpu": [
{
"test": "tests/models/yolos/test_modeling_yolos.py::YolosModelIntegrationTest::test_inference_object_detection_head",
"commit": "07a50c395552a28582c2746e06318e8f2e1bf059",
"status": "git bisect found the bad commit.",
"pr_number": null,
"author": "ydshieh",
"merged_by": null,
"parent": "377a8ee73f210476c4efb15170d0c32ad3b2c653"
}
]
}
}