mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
Hack SymInt.__iadd__ to be working. (#94136)
Signed-off-by: Edward Z. Yang <ezyang@meta.com> Pull Request resolved: https://github.com/pytorch/pytorch/pull/94136 Approved by: https://github.com/Skylion007
This commit is contained in:
parent
c1da35af5e
commit
834e8f0464
|
|
@ -243,6 +243,11 @@ class SymInt:
|
|||
def __int__(self):
|
||||
return self.node.int_()
|
||||
|
||||
# This is a hack, shouldn't be necessary. Helps
|
||||
# pyhpc_turbulent_kinetic_energy and vision_maskrcnn
|
||||
def __iadd__(self, other):
|
||||
return self + other
|
||||
|
||||
# Magic methods installed by torch.fx.experimental.symbolic_shapes
|
||||
|
||||
def __eq__(self, other: object) -> builtins.bool:
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user