pytorch
b5ff41a4 - [Dynamo] No graph break on calling dict & collections.OrderedDict() (#95250)

Commit
1 year ago
[Dynamo] No graph break on calling dict & collections.OrderedDict() (#95250) It's common to call ```dict()``` or ```collections.OrderedDict()``` inside of ```forward``` function, so we should not graph break. This pattern has been used in many places including: * The use case in [torchvision]( https://github.com/pytorch/vision/blob/928b05cad36eadb13e169f03028767c8bcd1f21d/torchvision/models/_utils.py#L66-L73). * It causes ~100 model failures(nopython=True) in the 14k github models. * Also it hits several Meta internal use cases. Pull Request resolved: https://github.com/pytorch/pytorch/pull/95250 Approved by: https://github.com/jansel
Author
Committer
Parents
Loading