Skip to content

NXP backend: Add QuantizeFusedConvBnBiasAtenPass call to integration tests pipeline#18904

Open
StrycekSimon wants to merge 4 commits intopytorch:mainfrom
nxp-upstream:feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test
Open

NXP backend: Add QuantizeFusedConvBnBiasAtenPass call to integration tests pipeline#18904
StrycekSimon wants to merge 4 commits intopytorch:mainfrom
nxp-upstream:feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test

Conversation

@StrycekSimon
Copy link
Copy Markdown
Collaborator

@StrycekSimon StrycekSimon commented Apr 15, 2026

Adds call to QuantizeFusedConvBnBiasAtenPass in conversion pipeline for integration tests. The pass enables QAT support for models containing biasless convolutions in integration tests.

Test plan

Covered by NXP internal tests.

cc @robert-kalmar @JakeStevens @digantdesai

Copilot AI review requested due to automatic review settings April 15, 2026 08:19
@pytorch-bot
Copy link
Copy Markdown

pytorch-bot Bot commented Apr 15, 2026

🔗 Helpful Links

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

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

❌ 2 Cancelled Jobs, 2 Unrelated Failures

As of commit 79f409c with merge base 8a97ac7 (image):

CANCELLED JOBS - The following jobs were cancelled. Please retry:

BROKEN TRUNK - The following jobs failed but were present on the merge base:

👉 Rebase onto the `viable/strict` branch to avoid these failures

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

@meta-cla meta-cla 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 Apr 15, 2026
@StrycekSimon StrycekSimon added release notes: nxp Changes to the NXP Neutron backend delegate and removed CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. labels Apr 15, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds an ATen-graph transform into the NXP integration-test quantization flow to better support QAT graphs that include biasless convolutions (by ensuring fused/introduced conv biases are quantized/dequantized appropriately before lowering).

Changes:

  • Import QuantizeFusedConvBnBiasAtenPass into the NXP integration-test utilities.
  • Invoke QuantizeFusedConvBnBiasAtenPass(default_zero_bias=True) after convert_pt2e(...) when use_qat is enabled.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread backends/nxp/tests_models/utils.py Outdated
Comment thread backends/nxp/tests_models/utils.py Outdated
@meta-cla meta-cla 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 Apr 15, 2026
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from f490656 to bf1c119 Compare April 22, 2026 13:50
@robert-kalmar robert-kalmar added the module: nxp Issues related to NXP Neutron NPU delegation and code under backends/nxp/ label Apr 23, 2026
Copilot AI review requested due to automatic review settings April 29, 2026 08:15
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from bf1c119 to 7b05fe1 Compare April 29, 2026 08:15
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread backends/nxp/quantizer/patterns.py
Comment thread backends/transforms/quantize_fused_convbn_bias_pass.py
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from 7b05fe1 to c5f0a07 Compare April 29, 2026 08:49
Copy link
Copy Markdown
Contributor

@JakeStevens JakeStevens left a comment

Choose a reason for hiding this comment

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

seems nxp tests are failing with incorrect number of nodes.

Doe sthis change reduce number of q/dq since activation and batch norm are observed togetehr with conv if fusable?

@StrycekSimon
Copy link
Copy Markdown
Collaborator Author

StrycekSimon commented Apr 29, 2026

I will look at this in a sec. I was primarily trying to resolve our internal tests hanging on this PR.

Edit: The tests expected bias to be introduced in biasless convolutions. This changed for PTQ after I introduced the conditioning of QuantizeFusedConvBnBiasAtenPass. I changed the default_zero_bias=False and adjusted the tests.

Copilot AI review requested due to automatic review settings April 29, 2026 19:44
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from c5f0a07 to 7e596ce Compare April 29, 2026 19:44
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread backends/nxp/quantizer/patterns.py
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from 7e596ce to 9763824 Compare April 30, 2026 07:46
Copilot AI review requested due to automatic review settings April 30, 2026 12:49
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from 9763824 to f500905 Compare April 30, 2026 12:49
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread backends/transforms/quantize_fused_convbn_bias_pass.py
Comment thread backends/transforms/quantize_fused_convbn_bias_pass.py Outdated
Comment thread backends/nxp/quantizer/utils.py
@StrycekSimon StrycekSimon force-pushed the feature/nxg10272/EIEX-757-enable-mlperftiny-vww-model-qat-training-test branch from f500905 to 79f409c Compare April 30, 2026 13:23
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. module: nxp Issues related to NXP Neutron NPU delegation and code under backends/nxp/ release notes: nxp Changes to the NXP Neutron backend delegate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants