Skip to content

Conversation

@justinchuby
Copy link
Collaborator

No description provided.

Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
@codecov
Copy link

codecov bot commented Jun 28, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 69.30%. Comparing base (7b89760) to head (f80a6ac).
⚠️ Report is 228 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2423   +/-   ##
=======================================
  Coverage   69.29%   69.30%           
=======================================
  Files         202      202           
  Lines       25773    25778    +5     
  Branches     2688     2688           
=======================================
+ Hits        17860    17865    +5     
  Misses       6988     6988           
  Partials      925      925           

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

num_outputs = outputs

metadata_props = {
"pkg.onnxscript.rewriter.stacktrace": _get_stacktrace(),
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should this always be added? Or, would it be better to do it only if the user sets some config/environment variable?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I think it's ok as a default? For example torch.export will add metadata as well. If user wants no stack traces they can run a pass, or if there's demand we can add an option to turn it off?

Copy link
Collaborator

Choose a reason for hiding this comment

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

But who's using this? What happens when multiple rewrites happen? Trying to understand what exactly the use-case is and what the users want.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

When we look at the graph from pytorch, all nodes can be traced back from source code in the torch model, but it is unclear which rule created the nodes that are added by the rewriter. So I was trying to add this information. A node can only be created once so multiple rewrites should not affect this field

@justinchuby justinchuby marked this pull request as draft July 8, 2025 17:27
@justinchuby justinchuby self-assigned this Jan 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Development

Successfully merging this pull request may close these issues.

3 participants