[ONNX] Update Reducesum operator for opset 13#50532
[ONNX] Update Reducesum operator for opset 13#50532neginraoof merged 20 commits intopytorch:onnx_ms_1from
Conversation
💊 CI failures summary and remediationsAs of commit 4061597 (more details on the Dr. CI page):
🕵️ 5 new failures recognized by patternsThe following CI failures do not appear to be due to upstream breakages:
|
neginraoof
left a comment
There was a problem hiding this comment.
Is pending squeeze/unsqueeze PR.
torch/onnx/symbolic_opset13.py
Outdated
| from torch.onnx.utils import _add_block, _add_input_to_block, _add_output_to_block | ||
|
|
||
| block_listed_operators = ['embedding_bag'] | ||
| block_listed_operators = [''] |
There was a problem hiding this comment.
Thanks. If block_listed_operators is empty and not used, please remove this and lines 15-16.
There was a problem hiding this comment.
Thanks, removed it. And also update the code in reducesum symbolics to use the helper function.
| return g.op('Mul', first, g.op('Sigmoid', second)) | ||
|
|
||
|
|
||
| def _reduce_op_symbolic(onnx_op_name): |
There was a problem hiding this comment.
Changes for sum and embedding_bag look good. Thanks.
7d16f5a to
d894078
Compare
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> [ghstack-poisoned]
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> [ghstack-poisoned]
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> [ghstack-poisoned]
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> Differential Revision: [D26023940](https://our.internmc.facebook.com/intern/diff/D26023940) [ghstack-poisoned]
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> [ghstack-poisoned]
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> Differential Revision: [D26050888](https://our.internmc.facebook.com/intern/diff/D26050888) [ghstack-poisoned]
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> Differential Revision: [D26050888](https://our.internmc.facebook.com/intern/diff/D26050888) [ghstack-poisoned]
Summary: Pull Request resolved: #50907 * udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Test Plan: Imported from OSS Reviewed By: pbelevich Differential Revision: D26050888 Pulled By: SplitInfinity fbshipit-source-id: 88307af6a7880abf94eac126ec1638e962de8c1f Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]>
* udpate symbolic for squeeze/unsqueeze * update c++ unsqueeze/squeeze creation * clang format * enable tests * clang format * remove prints * remove magic number * add helper function * fix build issue * update opset9 symbolic with helper function * fix utility test * fix prim_fallthrough opset skip * enable reducesum opset 13 * enable embedding_bag which contain reducesum op * add ReduceSum helper * remove block_listed_operators * remove local test code * remove embedding_bag() in opset13 file * remove unuse import Co-authored-by: BowenBao <[email protected]> Co-authored-by: hwangdeyu <[email protected]> ghstack-source-id: b85885b Pull Request resolved: pytorch#50907
embedding_bag which contains reducesum has also been updated.