| 626 | } |
| 627 | |
| 628 | bool mixin::OutshapePureByInshapeOpr::infer_desc( |
| 629 | size_t out_idx, TensorShape& dest, const StaticInferInpVal& inp) { |
| 630 | if (inp.run_id != m_inp_run_id) { |
| 631 | TensorShapeArray inp_shp(inp.val.size()); |
| 632 | for (size_t i = 0; i < inp_shp.size(); ++i) |
| 633 | inp_shp[i] = inp.val[i].shape(); |
| 634 | get_output_var_shape(inp_shp, m_out_shp); |
| 635 | mgb_assert(m_out_shp.size() == m_nr_managed_outputs); |
| 636 | m_inp_run_id = inp.run_id; |
| 637 | } |
| 638 | dest = m_out_shp.at(out_idx); |
| 639 | return true; |
| 640 | } |
| 641 | |
| 642 | /* =================== mixins::IOSameShapeOperatorNode =================== */ |
| 643 |
nothing calls this directly
no test coverage detected