Skip to content

Conversation

shewu-quic
Copy link
Collaborator

@shewu-quic shewu-quic commented Jun 26, 2025

Summary:

  • After QNN 2.35, op validation will check math invariant op should not change scale and offset. So, we should replace annotate_single_in_single_out with annotate_single_in_share_out to ensure not to change scale and offset
  • Fix the error for internal CI
  • Fix the bug for batch norm op

cc: @haowhsu-quic, @cccclai , @winskuo-quic

…ge scale and offset

Summary:
- After QNN 2.35, op validation will check math invariant op should not change scale and offset. So, we should replace annotate_single_in_single_out with annotate_single_in_share_out to ensure not to change scale and offset
- Fix the error for internal CI
- Fix the bug for batch norm op
- Fix the bug for index_put op
@shewu-quic shewu-quic requested a review from cccclai as a code owner June 26, 2025 01:11
Copy link

pytorch-bot bot commented Jun 26, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/11989

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 063a196 with merge base 3b0f7c8 (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jun 26, 2025
Copy link

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@cccclai
Copy link
Contributor

cccclai commented Jun 26, 2025

Is there a list of math invariant op from qnn?

@shewu-quic
Copy link
Collaborator Author

shewu-quic commented Jun 26, 2025

Is there a list of math invariant op from qnn?

It can be found in qnn doc. Operations>Backend supplements>HTP>Quantization.
And also if you modify the quant_attr for math invariant op, you will get the error such as the below.

[ERROR] [Qnn ExecuTorch]:  <E> This op is math invariant, input0 scale (0.000308) and output0 scale (0.000306) should be identical but is not.
 
[ERROR] [Qnn ExecuTorch]:  <E> QnnBackend_validateOpConfig failed 3110
 
[ERROR] [Qnn ExecuTorch]:  <E> Failed to validate op aten_expand_copy_default_15 with error 0xc26

image

@facebook-github-bot
Copy link
Contributor

@cccclai has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@cccclai cccclai merged commit bf9cd34 into pytorch:main Jun 29, 2025
97 of 99 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants