aboutsummaryrefslogtreecommitdiffstats
path: root/searchlib
diff options
context:
space:
mode:
authorArne Juul <arnej@verizonmedia.com>2020-03-23 14:10:59 +0000
committerArne Juul <arnej@verizonmedia.com>2020-03-23 14:30:35 +0000
commit3967677db35ec4d9805c5a410a2a083472fb6dd1 (patch)
tree292662ea5346c176324d7729e7eca3fd320436f6 /searchlib
parent9be49315bc1fe7efa35eea5a244c2ce85c03c701 (diff)
track API changes
Diffstat (limited to 'searchlib')
-rw-r--r--searchlib/src/tests/attribute/tensorattribute/tensorattribute_test.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/searchlib/src/tests/attribute/tensorattribute/tensorattribute_test.cpp b/searchlib/src/tests/attribute/tensorattribute/tensorattribute_test.cpp
index e6eb01596a8..001991d169c 100644
--- a/searchlib/src/tests/attribute/tensorattribute/tensorattribute_test.cpp
+++ b/searchlib/src/tests/attribute/tensorattribute/tensorattribute_test.cpp
@@ -26,6 +26,7 @@ LOG_SETUP("tensorattribute_test");
using document::WrongTensorTypeException;
using search::AttributeGuard;
using search::AttributeVector;
+using search::attribute::DistanceMetric;
using search::attribute::HnswIndexParams;
using search::tensor::DefaultNearestNeighborIndexFactory;
using search::tensor::DenseTensorAttribute;
@@ -147,6 +148,8 @@ public:
(void) explore_k;
return std::vector<Neighbor>();
}
+
+ search::tensor::DistanceFunction *distance_function() const override { return nullptr; }
};
class MockNearestNeighborIndexFactory : public NearestNeighborIndexFactory {
@@ -195,7 +198,7 @@ struct Fixture
_denseTensors = true;
}
if (enable_hnsw_index) {
- _cfg.set_hnsw_index_params(HnswIndexParams(4, 20));
+ _cfg.set_hnsw_index_params(HnswIndexParams(4, 20, DistanceMetric::Euclidean));
if (use_mock_index) {
_index_factory = std::make_unique<MockNearestNeighborIndexFactory>();
}