MS-267 default support IP

Former-commit-id: 64bfb03ea5291604f551530bc65896cc19841a5d
This commit is contained in:
xj.lin 2019-07-24 10:33:41 +08:00
parent 813f5151e8
commit 7b3886fd23

View File

@ -192,7 +192,7 @@ server::KnowhereError write_index(VecIndexPtr index, const std::string &location
void AutoGenParams(const IndexType &type, const long &size, zilliz::knowhere::Config &cfg) {
if (!cfg.contains("nlist")) { cfg["nlist"] = int(size / 1000000.0 * 16384); }
if (!cfg.contains("gpu_id")) { cfg["gpu_id"] = int(0); }
if (!cfg.contains("metric_type")) { cfg["metric_type"] = "L2"; }
if (!cfg.contains("metric_type")) { cfg["metric_type"] = "IP"; } // TODO: remove
switch (type) {
case IndexType::FAISS_IVFSQ8_MIX: {