Skip to content

Conversation

@ajrasane
Copy link
Contributor

@ajrasane ajrasane commented Jan 13, 2026

What does this PR do?

Type of change:
Bug fix

Overview:
Disable dq_only flag by default in modelopt onnx quantization

Testing

Able to build and run model with modelopt onnx Python CLI

  • Make sure you read and follow Contributor guidelines and your commits are signed.
  • Is this change backward compatible?: No
  • dq_only is set to False by default
  • Did you write any new necessary tests?: No
  • Did you add or update any necessary documentation?: No
  • Did you update Changelog?: No

Summary by CodeRabbit

Release Notes

  • Chores
    • Updated quantization default behavior: Q/DQ (Quantize/Dequantize) nodes are now added by default instead of only Dequantize nodes.

✏️ Tip: You can customize this high-level summary in your review settings.

@ajrasane ajrasane requested a review from a team as a code owner January 13, 2026 20:34
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jan 13, 2026

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

📝 Walkthrough

Walkthrough

The default value of the dq_only parameter in the quantize() function is changed from True to False. The parameter documentation is updated to clarify that when dq_only is False (the new default), both Q/DQ nodes are added; when True, only DQ nodes are added.

Changes

Cohort / File(s) Summary
Default parameter behavior
modelopt/onnx/quantization/quantize.py
Changed dq_only parameter default from True to False in quantize() method signature; updated docstring to document the new default behavior and clarify node insertion logic

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title '[NVBUG 5801937] Disable dq_only by default' directly and clearly summarizes the main change: switching the dq_only parameter default from True to False in the quantize function.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Signed-off-by: ajrasane <131806219+ajrasane@users.noreply.github.com>
@ajrasane ajrasane force-pushed the ajrasane/nvbug_5801937 branch from b1cd3f6 to 43cc715 Compare January 13, 2026 20:38
@codecov
Copy link

codecov bot commented Jan 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.19%. Comparing base (5e0d365) to head (43cc715).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #777      +/-   ##
==========================================
- Coverage   74.62%   74.19%   -0.44%     
==========================================
  Files         192      192              
  Lines       18989    18977      -12     
==========================================
- Hits        14171    14080      -91     
- Misses       4818     4897      +79     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@kevalmorabia97 kevalmorabia97 enabled auto-merge (squash) January 13, 2026 21:10
@kevalmorabia97 kevalmorabia97 merged commit b4c77c0 into main Jan 13, 2026
36 checks passed
@kevalmorabia97 kevalmorabia97 deleted the ajrasane/nvbug_5801937 branch January 13, 2026 22:20
jingyu-ml pushed a commit that referenced this pull request Jan 14, 2026
## What does this PR do?

**Type of change:**
Bug fix

**Overview:**
Disable dq_only flag by default in modelopt onnx quantization

## Testing
Able to build and run model with modelopt onnx Python CLI

- **Make sure you read and follow [Contributor
guidelines](https://github.com/NVIDIA/Model-Optimizer/blob/main/CONTRIBUTING.md)**
and your commits are signed.
- **Is this change backward compatible?**: No
- dq_only is set to False by default
- **Did you write any new necessary tests?**: No
- **Did you add or update any necessary documentation?**: No
- **Did you update
[Changelog](https://github.com/NVIDIA/Model-Optimizer/blob/main/CHANGELOG.rst)?**:
No

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

## Release Notes

* **Chores**
* Updated quantization default behavior: Q/DQ (Quantize/Dequantize)
nodes are now added by default instead of only Dequantize nodes.

<sub>✏️ Tip: You can customize this high-level summary in your review
settings.</sub>

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Signed-off-by: ajrasane <131806219+ajrasane@users.noreply.github.com>
Signed-off-by: Jingyu Xin <jingyux@nvidia.com>
kevalmorabia97 pushed a commit that referenced this pull request Jan 14, 2026
## What does this PR do?

**Type of change:** 
Bug fix

**Overview:**
Disable dq_only flag by default in modelopt onnx quantization

## Testing
Able to build and run model with modelopt onnx Python CLI

- **Make sure you read and follow [Contributor
guidelines](https://github.com/NVIDIA/Model-Optimizer/blob/main/CONTRIBUTING.md)**
and your commits are signed.
- **Is this change backward compatible?**: No
- dq_only is set to False by default
- **Did you write any new necessary tests?**: No
- **Did you add or update any necessary documentation?**: No
- **Did you update
[Changelog](https://github.com/NVIDIA/Model-Optimizer/blob/main/CHANGELOG.rst)?**:
No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

## Release Notes

* **Chores**
* Updated quantization default behavior: Q/DQ (Quantize/Dequantize)
nodes are now added by default instead of only Dequantize nodes.

<sub>✏️ Tip: You can customize this high-level summary in your review
settings.</sub>

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Signed-off-by: ajrasane <131806219+ajrasane@users.noreply.github.com>
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.

4 participants