Skip to content

Conversation

@Gasoonjia
Copy link
Contributor

Summary:
X-link: pytorch/ao#2339

This diff replace the debug handle with from_node infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation. For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle from from_node info via hasing.

After this change user no longer need to invoke generate_numeric_debug_handle for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997

@pytorch-bot
Copy link

pytorch-bot bot commented Jun 10, 2025

🔗 Helpful Links

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

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

❌ 1 New Failure

As of commit fe54b74 with merge base 67b6009 (image):

NEW FAILURE - The following job has failed:

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 10, 2025
@facebook-github-bot
Copy link
Contributor

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

@Gasoonjia
Copy link
Contributor Author

@pytorchbot label "release notes: none"

@pytorch-bot pytorch-bot bot added the release notes: none Do not include this in the release notes label Jun 12, 2025
@facebook-github-bot
Copy link
Contributor

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

Gasoonjia added a commit to Gasoonjia/executorch-1 that referenced this pull request Jun 12, 2025
pytorch#11532)

Summary:
Pull Request resolved: pytorch#11532

X-link: pytorch/ao#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
Gasoonjia added a commit to Gasoonjia/ao that referenced this pull request Jun 12, 2025
pytorch#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: pytorch#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
Gasoonjia added a commit to Gasoonjia/ao that referenced this pull request Jun 12, 2025
pytorch#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: pytorch#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
Gasoonjia added a commit to Gasoonjia/ao that referenced this pull request Jun 12, 2025
pytorch#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: pytorch#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
@facebook-github-bot
Copy link
Contributor

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

Gasoonjia added a commit to Gasoonjia/executorch-1 that referenced this pull request Jun 12, 2025
pytorch#11532)

Summary:
Pull Request resolved: pytorch#11532

X-link: pytorch/ao#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
@facebook-github-bot
Copy link
Contributor

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

Gasoonjia added a commit to Gasoonjia/executorch-1 that referenced this pull request Jun 12, 2025
pytorch#11532)

Summary:
Pull Request resolved: pytorch#11532

X-link: pytorch/ao#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
pytorch#11532)

Summary:
Pull Request resolved: pytorch#11532

X-link: pytorch/ao#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
@facebook-github-bot
Copy link
Contributor

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

Gasoonjia added a commit to Gasoonjia/ao that referenced this pull request Jun 18, 2025
pytorch#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: pytorch#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
Gasoonjia added a commit to pytorch/ao that referenced this pull request Jun 18, 2025
#2339)

Replace debug handle with `from_node` to trace operator transformation (#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: #2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
xiaowangintel pushed a commit to xiaowangintel/ao that referenced this pull request Jun 24, 2025
pytorch#2339)

Replace debug handle with `from_node` to trace operator transformation (pytorch#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: pytorch#2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
nonlocal prev_decomp_op_to_debug_handle_map
if FROM_NODE_KEY in node.meta:
prev_decomp_op = str(node.meta.get("nn_module_stack"))
debug_handle = _generate_debug_handle_from_node(node)
Copy link
Contributor

Choose a reason for hiding this comment

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

is from_node a new thing?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it is introduced after torch 2.6 and we will use that to trace the node transformation from torch.export to torchao to edge.

Copy link
Contributor

@digantdesai digantdesai left a comment

Choose a reason for hiding this comment

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

This is mainly updating the test, so ok with merging this.

liangel-02 pushed a commit to pytorch/ao that referenced this pull request Aug 25, 2025
#2339)

Replace debug handle with `from_node` to trace operator transformation (#2339)

Summary:
X-link: pytorch/executorch#11532

Pull Request resolved: #2339

This diff replace the debug handle  with `from_node` infrastructure, which is a first class citizen in exported program and used to trace the node-level transformation by recording every ancestor of given node. N6213836 is a demonstration of how `from_node` infra records the node transformation after unlifting and re-exporting exported graph.

For simplify the progress, we are trying to reuse the debug handle infrastructure by generating debug handle with hashing their greatest ancestor's node.

After this change user no longer need to invoke `generate_numeric_debug_handle` for debugging. Also the original pipeline will still work under current scenario.

Reviewed By: jerryzh168

Differential Revision: D76168997
@github-actions
Copy link

github-actions bot commented Sep 2, 2025

Looks like this PR hasn't been updated in a while so we're going to go ahead and mark this as Stale.
Feel free to remove the Stale label if you feel this was a mistake.
If you are unable to remove the Stale label please contact a maintainer in order to do so.
If you want the bot to never mark this PR stale again, add the no-stale label.
Stale pull requests will automatically be closed after 30 days of inactivity.

@github-actions github-actions bot added the stale PRs inactive for over 60 days label Sep 2, 2025
@github-actions
Copy link

github-actions bot commented Nov 1, 2025

Looks like this PR hasn't been updated in a while so we're going to go ahead and mark this as Stale.
Feel free to remove the Stale label if you feel this was a mistake.
If you are unable to remove the Stale label please contact a maintainer in order to do so.
If you want the bot to never mark this PR stale again, add the no-stale label.
Stale pull requests will automatically be closed after 30 days of inactivity.

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. fb-exported release notes: none Do not include this in the release notes stale PRs inactive for over 60 days

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants