| 39 | } |
| 40 | |
| 41 | void BoxingZerosTaskNode::BuildExecGphAndRegst() { |
| 42 | ExecNode* node = mut_exec_gph().NewNode(); |
| 43 | OperatorConf op_conf; |
| 44 | op_conf.set_name("System-Boxing-Zeros-" + NewUniqueId()); |
| 45 | op_conf.set_device_tag(*CHECK_JUST(DeviceTag4DeviceType(this->device_type()))); |
| 46 | *op_conf.mutable_boxing_zeros_conf()->mutable_lbi() = lbi(); |
| 47 | shape_.ToProto(op_conf.mutable_boxing_zeros_conf()->mutable_shape()); |
| 48 | op_conf.mutable_boxing_zeros_conf()->set_data_type(data_type_); |
| 49 | std::shared_ptr<Operator> sole_op = CHECK_JUST(ConstructOp(op_conf)); |
| 50 | node->mut_op() = sole_op; |
| 51 | std::shared_ptr<RegstDesc> out_regst = GetProducedRegst("out"); |
| 52 | out_regst->AddLbi(sole_op->BnInOp2Lbi(sole_op->SoleObn())); |
| 53 | node->BindBnWithRegst(sole_op->SoleObn(), out_regst); |
| 54 | (node->*GetInferBlobDescsMethod())(nullptr); |
| 55 | } |
| 56 | |
| 57 | void BoxingZerosTaskNode::InferProducedDataRegstTimeShape() { |
| 58 | GetProducedRegst("out")->mut_data_regst_time_shape()->reset(new Shape(time_shape_)); |
nothing calls this directly
no test coverage detected