Index Parameter Range
Searching with most indexes that Milvus supported requires specifying construction and search parameters. Listed below are the type and ranges of these parameters.
Index | Type | Const. Param & Range | Search Param & Range | Note |
---|---|---|---|---|
Flat | entity.Flat | N/A | N/A | No parameter is required for search with Flat. |
BinFlat | entity.BinFlat | nlist ∈[1, 65536] |
nprobe ∈[1, nlist ] |
|
IvfFlat | entity.IvfFlat | nlist ∈[1, 65536] |
nprobe ∈[1, nlist ] |
|
BinIvfFlat | entity.BinIvfFlat | nlist ∈[1, 65536] |
nprobe ∈[1, nlist ] |
BinIvfFlat will be supported in upcoming version of Milvus. |
IvfSQ8 | entity.IvfSQ8 | nlist ∈[1, 65536] |
nprobe ∈[1, nlist ] |
|
IvfSQ8H | entity.IvfSQ8H | nlist ∈[1, 65536] |
nprobe ∈[1, nlist ] |
|
IvfPQ | entity.IvfPQ | nlist ∈[1, 65536]m dim===0 (mod self)nbits ∈[1, 16] |
nprobe ∈[1, nlist ] |
|
RNSG | entity.NSG | out_degree ∈[5, 300]candidate_pool_size ∈[50, 1000]search_length ∈[10, 300]knng ∈[5, 300] |
search_length ∈[10, 300] |
|
HNSW | entity.HNSW | M ∈[4, 64]efConstruction ∈[8, 512] |
ef ∈[topK, 32768] |
|
RHNSWFlat | entity.RHNSWFlat | M ∈[4, 64]efConstruction ∈[8, 512] |
ef ∈[topK, 32768] |
|
RHNSW_PQ | entity.RHNSW_PQ | M ∈[4, 64]efConstruction ∈[8, 512]PQM dim===0 (mod self) |
ef ∈[topK, 32768] |
|
RHNSW_SQ | entity.RHNSWSQ | M ∈[4, 64]efConstruction ∈[8, 512] |
ef ∈[topK, 32768] |
|
IvfHNSW | entity.IvfHNSW | nlist ∈[1, 65536]M ∈[4, 64]efConstruction ∈[8, 512] |
nprobe ∈[1, nlist ]ef ∈[topK, 32768] |
|
ANNOY | entity.ANNOY | n_trees ∈[1, 1024] |
search_k ∈-1 or [topk, n * n_trees] |
|
NGTPANNG | entity.NGTPANNG | edge_size ∈[1, 200]forcedly_pruned_edge_size ∈[selectively_pruned_edge_size + 1, 200]selectively_pruned_edge_size ∈[1, forcedly_pruned_edge_size -1 ] |
max_search_edges ∈[-1, 200]epsilon ∈[-1.0, 1.0] |
Search parameter epsilon type is float64. |
NGTONNG | entity.NGTONNG | edge_size ∈[1, 200]outgoing_edge_size ∈[1, 200]incoming_edge_size ∈[1, 200] |
max_search_edges ∈[-1, 200]epsilon ∈[-1.0, 1.0] |
Search parameter epsilon type is float64. |