@@ -243,7 +243,7 @@ Status ModelBuilder::SetInputOutputDesc() { | |||||
} | } | ||||
// if user set input node format ND, the expected node for data and netoutput format is ND in | // if user set input node format ND, the expected node for data and netoutput format is ND in | ||||
// final graph. | // final graph. | ||||
if ((GetLocalOmgContext().format == domi::DOMI_TENSOR_ND) && (!node_op_desc->HasAttr("_is_single_op")) && | |||||
if ((compute_graph_->GetParentGraph() == nullptr) && (GetLocalOmgContext().format == domi::DOMI_TENSOR_ND) && (!node_op_desc->HasAttr("_is_single_op")) && | |||||
((node_op_desc->GetType() == DATA_TYPE) || (node_op_desc->GetType() == NETOUTPUT))) { | ((node_op_desc->GetType() == DATA_TYPE) || (node_op_desc->GetType() == NETOUTPUT))) { | ||||
auto inputDescsPtr = node_op_desc->GetAllInputsDescPtr(); | auto inputDescsPtr = node_op_desc->GetAllInputsDescPtr(); | ||||
auto outputDescsPtr = node_op_desc->GetAllOutputsDescPtr(); | auto outputDescsPtr = node_op_desc->GetAllOutputsDescPtr(); | ||||
@@ -319,7 +319,7 @@ vector<void *> ModelUtils::GetInputDataAddrs(const RuntimeParam &model_param, Co | |||||
const GeTensorDescPtr tensor_desc = op_desc->MutableInputDesc(static_cast<uint32_t>(i)); | const GeTensorDescPtr tensor_desc = op_desc->MutableInputDesc(static_cast<uint32_t>(i)); | ||||
GE_IF_BOOL_EXEC(tensor_desc == nullptr, GELOGD("Op: %s, Index: %zu, has no input", op_desc->GetName().c_str(), i); | GE_IF_BOOL_EXEC(tensor_desc == nullptr, GELOGD("Op: %s, Index: %zu, has no input", op_desc->GetName().c_str(), i); | ||||
continue;) | continue;) | ||||
if ((i < v_is_input_const.size()) && v_is_input_const[i] && (op_type != NETOUTPUT)) { | |||||
if ((i < v_is_input_const.size()) && v_is_input_const[i]) { | |||||
// TBE: add weights address to input | // TBE: add weights address to input | ||||
int64_t tensor_size = 0; | int64_t tensor_size = 0; | ||||
GE_CHK_STATUS(TensorUtils::GetSize(*tensor_desc, tensor_size)); | GE_CHK_STATUS(TensorUtils::GetSize(*tensor_desc, tensor_size)); | ||||
@@ -1541,7 +1541,9 @@ Status HybridModelBuilder::IdentifyVariableOutputs(NodeItem &node_item) { | |||||
src_node->GetName().c_str(), | src_node->GetName().c_str(), | ||||
src_op_type.c_str()); | src_op_type.c_str()); | ||||
uint32_t parent_index = 0; | uint32_t parent_index = 0; | ||||
GE_CHK_STATUS_RET_NOLOG(GetParentNodeOutputIndex(*net_output_desc, in_data_anchor->GetIdx(), parent_index)); | |||||
if (GetParentNodeOutputIndex(*net_output_desc, in_data_anchor->GetIdx(), parent_index) != SUCCESS) { | |||||
continue; | |||||
} | |||||
GELOGD("Got parent output index = %u", parent_index); | GELOGD("Got parent output index = %u", parent_index); | ||||
if (src_op_type == DATA) { | if (src_op_type == DATA) { | ||||
int ref_i = 0; | int ref_i = 0; | ||||