-
Notifications
You must be signed in to change notification settings - Fork 26.3k
[jit] bake constants into the traced graph, get rid of getNestedValueTrace #21046
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
…NestedValueTrace" [jit] bake constants into the traced graph, get rid of getNestedValueTrace gh-metadata: pytorch pytorch 21046 gh/wanchaol/13/head
…rid of getNestedValueTrace" [jit] bake constants into the traced graph, get rid of getNestedValueTrace gh-metadata: pytorch pytorch 21046 gh/wanchaol/13/head
|
Why does is this stacked with the other PRs? |
@eellison it has no relation with the bottom PRs, it's just that I was lazy at creating a new branch for it lol... I can move it to a separate branch if you prefer :) |
zdevito
left a comment
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.
Looks good, but needs to have error handling and a test for the error handline.
…NestedValueTrace" [jit] bake constants into the traced graph, get rid of getNestedValueTrace gh-metadata: pytorch pytorch 21046 gh/wanchaol/13/head
…id of getNestedValueTrace" [jit] bake constants into the traced graph, get rid of getNestedValueTrace gh-metadata: pytorch pytorch 21046 gh/wanchaol/13/head
…NestedValueTrace" [jit] bake constants into the traced graph, get rid of getNestedValueTrace gh-metadata: pytorch pytorch 21046 gh/wanchaol/13/head
Stack from ghstack:
When tracing a script function, we will stop the tracing state and try to inline the scripted graph, but if the scripted function contains non tensor types, we will fail to trace them as they are not generated by any previous ops or any constants.
This PR helps generate the constants when the tracing call try to inline the script function.
This should fix #21009
Differential Revision: D15530991