Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the CLIP image-classification demo’s model download/export flow to use optimum-intel for exporting the Hugging Face CLIP model to OpenVINO IR, along with updated Python requirements and a small .gitignore tweak.
Changes:
- Switch
download_model.pyfrom manualtransformers+openvino.convert_model()conversion toOVModelForZeroShotImageClassification(..., export=True)and save intomodel/1. - Update
download_model_requirements.txtto useoptimum-intel(VCS install) and loosentransformersconstraint. - Ignore
.github/skills/in the repo root.gitignore.
Reviewed changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| demos/python_demos/clip_image_classification/download_model.py | Replaces manual OpenVINO conversion with optimum-intel export + renaming of generated IR artifacts. |
| demos/python_demos/clip_image_classification/download_model_requirements.txt | Adjusts dependencies to support the new export path (optimum-intel, updated transformers constraint, etc.). |
| .gitignore | Adds an ignore rule for .github/skills/. |
Comment on lines
+31
to
+37
| for src, dst in ( | ||
| ("openvino_model.xml", "clip-vit-base-patch16.xml"), | ||
| ("openvino_model.bin", "clip-vit-base-patch16.bin"), | ||
| ): | ||
| src_path = os.path.join(model_path, src) | ||
| if os.path.exists(src_path): | ||
| os.replace(src_path, os.path.join(model_path, dst)) |
| --extra-index-url "https://storage.openvinotoolkit.org/simple/wheels/nightly" | ||
| --pre | ||
| openvino==2026.1.* | ||
| optimum-intel@git+https://github.com/huggingface/optimum-intel.git |
dtrawins
approved these changes
May 7, 2026
mzegla
approved these changes
May 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🛠 Summary
Quick fix for clip requirements
🧪 Checklist
``