KEMBAR78
debug handler maintain through decomposition by Gasoonjia · Pull Request #141612 · pytorch/pytorch · GitHub
Skip to content

Conversation

Gasoonjia
Copy link
Contributor

@Gasoonjia Gasoonjia commented Nov 26, 2024

Stack from ghstack (oldest at bottom):

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: D66517480

BC-breaking note

torch.ao.quantization.pt2e.graph_utils.get_control_flow_submodules is No Longer a Public API

We aim to make all functions under torch.ao.quantization.pt2e.graph_utils private. This update marks get_control_flow_submodules as a private API.

Currently, only bfs_trace_with_node_process remains public, but it will be marked private in the next release.

BC-breaking note

torch.ao.quantization.pt2e.graph_utils.get_control_flow_submodules is No Longer a Public API

We aim to make all functions under torch.ao.quantization.pt2e.graph_utils private. This update marks get_control_flow_submodules as a private API. If you have to or want to continue using get_control_flow_submodules, please make a private call by using _get_control_flow_submodules.

Currently, only bfs_trace_with_node_process remains public, but it will be marked private in the next release.

Example:
Version 2.6:

>>> from torch.ao.quantization.pt2e.graph_utils import get_control_flow_submodules

Version 2.7:

>>> from torch.ao.quantization.pt2e.graph_utils import get_control_flow_submodules
ImportError: cannot import name 'get_control_flow_submodules' from 'torch.ao.quantization.pt2e.graph_utils'
>>> from torch.ao.quantization.pt2e.graph_utils import _get_control_flow_submodules # Note: Use _get_control_flow_submodules for private access

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@pytorch-bot
Copy link

pytorch-bot bot commented Nov 26, 2024

🔗 Helpful Links

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

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

✅ No Failures

As of commit 639e389 with merge base 47a571e (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
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

@Gasoonjia
Copy link
Contributor Author

#suppress-bc-linter

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
Gasoonjia added a commit that referenced this pull request Nov 27, 2024
Pull Request resolved: #141612

Add checks in the ao numberic debugger to guard the debug handle consistency during aten op decomposition
ghstack-source-id: 255582376

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

@Gasoonjia Gasoonjia added the suppress-bc-linter Suppresses the failures of API backward-compatibility linter (Lint/bc_linter) label Nov 27, 2024
@pytorch-bot pytorch-bot bot added the ciflow/trunk Trigger trunk jobs on your pull request label Dec 10, 2024
Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@Gasoonjia Gasoonjia requested a review from albanD as a code owner December 10, 2024 09:29
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

"node_arg_is_weight",
"return_arg_list",
# torch.ao.quantization.pt2e.graph_utils
"bfs_trace_with_node_process",
Copy link
Collaborator

Choose a reason for hiding this comment

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

Adding new entries in this file is not ok.
Please make sure that all the new public APIs that you add are properly documented and show up on the website.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the feedback. Any example I can use for documentation? I noticed that all public APIs under torch.ao.quantization.pt2e.graph_utils are in this file and (looks like) there's not any doc for graph_utils.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If allowed, we can first add bfs_trace_with_node_process here, and have another PR for all doc stuff under graph_utils.

Copy link
Contributor

Choose a reason for hiding this comment

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

graph_utils shouldn't be public API, I'd recommend to make this private (add _)

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

Gasoonjia added a commit that referenced this pull request Dec 10, 2024
Pull Request resolved: #141612

Add checks in the ao numberic debugger to guard the debug handle consistency during aten op decomposition
ghstack-source-id: 257550559

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)
Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

Add checks in the ao numberic debugger to guard the debug handle consistency between aten op decomposition

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)

[ghstack-poisoned]
Gasoonjia added a commit that referenced this pull request Dec 12, 2024
Pull Request resolved: #141612

Add checks in the ao numberic debugger to guard the debug handle consistency during aten op decomposition
ghstack-source-id: 257747832

Differential Revision: [D66517480](https://our.internmc.facebook.com/intern/diff/D66517480/)
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D66517480

@facebook-github-bot
Copy link
Contributor

@pytorchbot merge

(Initiating merge automatically since Phabricator Diff has merged)

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

@github-actions github-actions bot deleted the gh/Gasoonjia/3/head branch January 14, 2025 02:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request fb-exported Merged release notes: quantization release notes category suppress-bc-linter Suppresses the failures of API backward-compatibility linter (Lint/bc_linter)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants