Merge pull request #23645 from Abdurrahheem:ash/tf_init_input_check

Add assert to check if layer input size is not empty
pull/23652/head
Alexander Smorkalov 2 years ago committed by GitHub
commit f2311d1bfd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      modules/dnn/src/tensorflow/tf_graph_simplifier.cpp

@ -815,6 +815,7 @@ void RemoveIdentityOps(tensorflow::GraphDef& net)
if (type == "Identity" || type == "Dropout" || type == "PlaceholderWithDefault") {
identity_ops_idx.push_back(li);
CV_Assert(layer.input_size() != 0);
identity_ops[layer.name()] = layer.input(0);
}
}

Loading…
Cancel
Save