pytorch
66745831 - [ONNX] Support constant 'aten::__contains__' (#91660)

Commit
1 year ago
[ONNX] Support constant 'aten::__contains__' (#91660) #84624 introduces an update on `torch.norm` [dispatch logic](https://github.com/pytorch/pytorch/blob/eaa43d9f254fa01ee2d61dc2932c4e48987d7f96/torch/functional.py#L1489) which now depends on `layout`. Resulting in regressions to export related operators from TorchScript. This PR resolves the regression by partially supporting a subset use case of `prim::layout` (only `torch.strided`), `aten::__contains__` (only constants) operators. It requires much more effort to properly support other layouts, e.g. `torch.sparse_coo`. Extending JIT types, and supporting related family of ops like `aten::to_sparse`. This is out of the scope of this PR. Fixes #83661 Pull Request resolved: https://github.com/pytorch/pytorch/pull/91660 Approved by: https://github.com/justinchuby, https://github.com/kit1980
Author
Committer
Parents
Loading