Function Description
Sets the actual number of inputs corresponding to an input defined by the IR.
Function Prototype
void SetInstantiationNum(const uint32_t instantiation_num)
Parameters
| Parameter | Input/Output | Description |
| instantiation_num | Input | Number of instantiated inputs. |
Calling Example
const auto &ir_inputs = node->GetOpDesc()->GetIrInputs(); // All inputs defined by the operator IR
for (size_t i = 0; i < ir_inputs.size(); ++i) {
auto ins_info = compute_node_info.MutableInputInstanceInfo(i); // Obtain the AnchorInstanceInfo object corresponding to the *i*th IR input.
GE_ASSERT_NOTNULL(ins_info);
size_t instance_num = ir_index_to_instance_index_pair_map[i].second; // Obtain the actual number of inputs corresponding to the operator IR input after statistics collection.
ins_info->SetInstantiationNum(instance_num); // Save the information to the AnchorInstanceInfo object corresponding to the IR input.
}