Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add qnn examples of clip models. #1616

Merged
merged 13 commits into from
Feb 19, 2025
Merged

Add qnn examples of clip models. #1616

merged 13 commits into from
Feb 19, 2025

Conversation

chinazhangchao
Copy link
Contributor

@chinazhangchao chinazhangchao commented Feb 14, 2025

Describe your changes

Add qnn examples of clip models:

  • openai/clip-vit-base-patch16
  • openai/clip-vit-base-patch32
  • openai/clip-vit-large-patch14

Checklist before requesting a review

  • Add unit tests for this change.
  • Make sure all tests can pass.
  • Update documents if necessary.
  • Lint and apply fixes to your code by running lintrunner -a
  • Is this a user-facing change? If yes, give a description of this change to be included in the release notes.
  • Is this PR including examples changes? If yes, please remember to update example documentation in a follow-up PR.

Metrics

image

(Optional) Issue link

Copy link

@github-advanced-security github-advanced-security bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lintrunner found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.

@chinazhangchao chinazhangchao changed the title Chao/clip Add qnn examples of clip models. Feb 18, 2025
"type": "OnnxStaticQuantization",
"quant_preprocess": true,
"data_config": "quant_data_config",
"op_types_to_quantize": [ "MatMul", "LayerNormalization", "Gemm", "Sigmoid", "Gelu" ],
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: the line "op_types_to_quantize": [ "MatMul", "LayerNormalization", "Gemm", "Sigmoid", "Gelu" ], in the json configurations are not effective due to known Olive issues, but has been left in place for future use.
#1552

This reverts commit 81bd4f3.
@chinazhangchao chinazhangchao marked this pull request as ready for review February 18, 2025 05:26
"sub_types": [
{ "name": "accuracy", "priority": 1, "goal": { "type": "max-degradation", "value": 0.05 } }
],
"user_config": {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: since the target ep is qnn, this config is not needed if you want to run on qnn ep.

@chinazhangchao chinazhangchao merged commit 2dcb0fe into main Feb 19, 2025
24 checks passed
@chinazhangchao chinazhangchao deleted the chao/clip branch February 19, 2025 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants