Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

BestOf2NearestMatcher gives different result on second run

When I excecute the folloing code twice with the exact same inputs, I get two different but similar results. Am I doing domething wrong or is this a bug?

BestOf2NearestMatcher matcher(false, 0.3);
vector<MatchesInfo> temp_pairwise_matches = [...];
vector<ImageFeatures> temp_features = [...];
matcher(temp_features, pairwise_matches);
matcher.collectGarbage();

A little more info: I have spend a lot of time isolating the problem to this code. I create two different copies of BestOf2NearestMatcher and all input data is being cloned, so there is definitively no change in the input. The result on the first run is always the same and so is the result on the second and third run, and so on. But none of the results equals one of the previous results.