1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 07:13:02 +04:00

Merge pull request #23645 from Abdurrahheem:ash/tf_init_input_check

Add assert to check if layer input size is not empty
This commit is contained in:
Alexander Smorkalov
2023-05-19 13:28:24 +03:00
committed by GitHub
@@ -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);
}
}