flann: fix AutotunedIndex crashing if a KDTree index is selected

Backport of mariusmuja/flann@f8ca6df3.
This commit is contained in:
Roman Donchenko 2015-07-29 18:03:48 +03:00
parent 6b954cd24e
commit c2f59a0f73

View File

@ -384,6 +384,7 @@ private:
// evaluate kdtree for all parameter combinations
for (size_t i = 0; i < FLANN_ARRAY_LEN(testTrees); ++i) {
CostData cost;
cost.params["algorithm"] = FLANN_INDEX_KDTREE;
cost.params["trees"] = testTrees[i];
evaluate_kdtree(cost);