How to extract a 2D vector from 4D Mat and get maximum value
Hi to all, I am playing a bit with dnn to improve my know how. I pass a camera frame through a network. Based on documentation at the official link
the output is a Mat with this shape
"shape: [1, 2, 1, 1] - Softmax output across 2 type classes".
So I would extract automatically the values at the indexes (0,0,0,0) and (0,1,0,0), store them in a vector<float> and get the maximum value between them. Is there a way to do it automatically in C++? Thank in advance Franco