lundi 18 juillet 2016

Search value in OpenCV vector

I can't find in the docs any implementstion, that will show, how i can retrieve indexes of values in vector (1d matrix), that have matching values. The closest example is:

Mat b;
Mat a = b == 5;

So this should give me a matrix of booleans. And then I can use it to extract indexes of values that are equal to 5. Is there a more performant way? It should send all the values in vector to the GPU in parallel and then return the index of the only (or first) value that equals 5. And it shouldn't be anything from "algorithm" framework, like:

std::find(...);

Only interested in parallel GPU solutions.

Aucun commentaire:

Enregistrer un commentaire