Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor index_remapping_array initialization for PT2 export (pytorch…
…#2424) Summary: Pull Request resolved: pytorch#2424 We end up getting this error ``` torch.fx.experimental.symbolic_shapes.GuardOnDataDependentSymNode: Could not guard on data-dependent expression Eq(u0, 1) (unhinted: Eq(u0, 1)). (Size-like symbols: none) ``` w/ tracing `if self.index_remappings_array_offsets[-1] == 0` in FakeTensorMode. Changing it to check len(index_remapping) is logically the same, and seems to fix the error. Reviewed By: sryap Differential Revision: D54779307 fbshipit-source-id: 609402fa67a50f2bedfb3883413dfe3f7f6ca314
- Loading branch information