benchmark
1ca89b11 - Support FunctoolsPartialVariable::get_function, fix get_fake_values_from_nodes (#119435)

Commit
1 year ago
Support FunctoolsPartialVariable::get_function, fix get_fake_values_from_nodes (#119435) Summary: partially address https://github.com/pytorch/pytorch/issues/118785 This diff fixes three things: 1. add get_function to FunctoolsPartialVariable note that it will be available only if all args constant otherwise, it would throw unimplemented in the call to asPythonConstant. 2. NamedTupleVariable takes args dispatched not as list ex: NamedTuple(a, b, c) vs NamedTuple([a, b, c]), hence fix that by specializing asProxy. 3. A call to create_arg from within create_proxy, changes a python NamedTuple to a function call node without associating an example value! Updated get_fake_values_from_nodes to handle such case. X-link: https://github.com/pytorch/pytorch/pull/119435 Approved by: https://github.com/jansel, https://github.com/anijain2305 ghstack dependencies: #119314 Reviewed By: huydhn Differential Revision: D53693422 Pulled By: laithsakka fbshipit-source-id: 893c9b34117342f6e97c5221c2af8c5e1f29b739
Author
Parents
Loading