-
Notifications
You must be signed in to change notification settings - Fork 25.6k
[FX] Fix handling of attributes #47030
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is actually pretty close to what I was proposing, just need to get the specifics ironed out. Can you:
- Add the test case from the issue to
test_fx.py - Work out the issues with this on the other tests
💊 CI failures summary and remediationsAs of commit 6cc39cb (more details on the Dr. CI page): 💚 💚 Looks good so far! There are no failures yet. 💚 💚 This comment was automatically generated by Dr. CI (expand for details).Follow this link to opt-out of these comments for your Pull Requests.Please report bugs/suggestions on the GitHub issue tracker or post in the (internal) Dr. CI Users group. This comment has been revised 29 times. |
Codecov Report
@@ Coverage Diff @@
## master #47030 +/- ##
=======================================
Coverage 68.95% 68.95%
=======================================
Files 434 434
Lines 56207 56220 +13
=======================================
+ Hits 38760 38769 +9
- Misses 17447 17451 +4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice
test/test_fx.py
Outdated
| return self.a.b, self.a.b.t(), self.a.b.view(12) | ||
|
|
||
| traced = torch.fx.symbolic_trace(Foo()) | ||
| assert(all('constant' not in node.name for node in traced.graph.nodes)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh also don't match on name, that isn't stable. You can do this same check on node.target
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Chillee has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
Probably works :)
Fixes #46872