Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions diskann-benchmark/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -269,9 +269,9 @@ First, set up the runbook and ground truth for the desired workload. Refer to th

Benchmarks are run with
```sh
cargo run --release --package diskann-benchmark -- run --input-file ./diskann-benchmark/example/graph-index-dynamic.json --output-file dynamic-output.json
cargo run --release --package diskann-benchmark -- run --input-file ./diskann-benchmark/example/graph-index-stream.json --output-file stream-output.json
```
Note in the example json that the benchmark is registered under `graph-index-dynamic-run`,
Note in the example json that the benchmark is registered under `graph-index-stream-run`,
instead of `graph-index-build` etc..

A streaming run happens in several phases.
Expand Down
35 changes: 19 additions & 16 deletions diskann-benchmark/example/graph-index-bftree-spherical.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
],
"jobs": [
{
"type": "graph-index-build-bftree-spherical-quantization",
"type": "graph-index-bftree",
"content": {
"build": {
"data_type": "float32",
Expand Down Expand Up @@ -40,10 +40,24 @@
}
]
},
"seed": 42,
"transform_kind": "null",
"num_bits": 2,
"pre_scale": "reciprocal_mean_norm",
"quantization": {
"kind": "spherical",
"seed": 42,
"transform_kind": "null",
"num_bits": 2,
"pre_scale": "reciprocal_mean_norm",
"quant_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
"cb_max_record_size": null,
"cb_min_record_size": null,
"read_promotion_rate": null,
"scan_promotion_rate": null,
"cb_copy_on_access_ratio": null,
"read_record_cache": null,
"cache_only": null
}
},
"vector_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
Expand All @@ -65,17 +79,6 @@
"cb_copy_on_access_ratio": null,
"read_record_cache": null,
"cache_only": null
},
"quant_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
"cb_max_record_size": null,
"cb_min_record_size": null,
"read_promotion_rate": null,
"scan_promotion_rate": null,
"cb_copy_on_access_ratio": null,
"read_record_cache": null,
"cache_only": null
}
}
}
Expand Down
84 changes: 84 additions & 0 deletions diskann-benchmark/example/graph-index-bftree-stream-spherical.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
{
"search_directories": [
"test_data/disk_index_search"
],
"jobs": [
{
"type": "graph-index-stream-bftree",
"content": {
"build": {
"data_type": "float32",
"data": "disk_index_siftsmall_learn_256pts_data.fbin",
"distance": "squared_l2",
"max_degree": 32,
"l_build": 50,
"start_point_strategy": "medoid",
"alpha": 1.2,
"backedge_ratio": 1.0,
"num_threads": 1
},
"search": {
"queries": "disk_index_sample_query_10pts.fbin",
"reps": 1,
"num_threads": 1,
"search_l": 40,
"search_n": 10,
"recall_k": 10
},
"runbook_params": {
"runbook_path": "example_runbook.yaml",
"dataset_name": "sift-small-256",
"gt_directory": "example_runbook_gt",
"ip_delete_method": {
"method": "visited_and_top_k",
"params": {
"k_value": 10,
"l_value": 40
}
},
"ip_delete_num_to_replace": 3
},
"quantization": {
"kind": "spherical",
"seed": 42,
"transform_kind": "null",
"num_bits": 2,
"pre_scale": "reciprocal_mean_norm",
"quant_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
"cb_max_record_size": null,
"cb_min_record_size": null,
"read_promotion_rate": null,
"scan_promotion_rate": null,
"cb_copy_on_access_ratio": null,
"read_record_cache": null,
"cache_only": null
}
},
"vector_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
"cb_max_record_size": null,
"cb_min_record_size": null,
"read_promotion_rate": null,
"scan_promotion_rate": null,
"cb_copy_on_access_ratio": null,
"read_record_cache": null,
"cache_only": null
},
"neighbor_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
"cb_max_record_size": null,
"cb_min_record_size": null,
"read_promotion_rate": null,
"scan_promotion_rate": null,
"cb_copy_on_access_ratio": null,
"read_record_cache": null,
"cache_only": null
}
}
}
]
}
26 changes: 9 additions & 17 deletions diskann-benchmark/example/graph-index-bftree-stream.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
],
"jobs": [
{
"type": "graph-index-stream-bftree-full-precision",
"type": "graph-index-stream-bftree",
"content": {
"build": {
"data_type": "float32",
Expand All @@ -17,24 +17,13 @@
"backedge_ratio": 1.0,
"num_threads": 1
},
"search_phase": {
"search-type": "topk",
"search": {
"queries": "disk_index_sample_query_10pts.fbin",
"groundtruth": "disk_index_10pts_idx_uint32_truth_search_res.bin",
"reps": 1,
"num_threads": [
1
],
"runs": [
{
"search_n": 10,
"search_l": [
20,
40
],
"recall_k": 10
}
]
"num_threads": 1,
"search_l": 40,
"search_n": 10,
"recall_k": 10
},
"runbook_params": {
"runbook_path": "example_runbook.yaml",
Expand All @@ -49,6 +38,9 @@
},
"ip_delete_num_to_replace": 3
},
"quantization": {
"kind": "none"
},
"vector_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
Expand Down
5 changes: 4 additions & 1 deletion diskann-benchmark/example/graph-index-bftree.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
],
"jobs": [
{
"type": "graph-index-build-bftree-full-precision",
"type": "graph-index-bftree",
"content": {
"build": {
"data_type": "float32",
Expand Down Expand Up @@ -37,6 +37,9 @@
}
]
},
"quantization": {
"kind": "none"
},
"vector_store_config": {
"cb_size_byte": 67108864,
"leaf_page_size": 4096,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
],
"jobs": [
{
"type": "graph-index-dynamic-run",
"type": "graph-index-stream-run",
"content": {
"build": {
"data_type": "float32",
Expand All @@ -17,24 +17,13 @@
"num_threads": 4,
"start_point_strategy": "medoid"
},
"search_phase": {
"search-type": "topk",
"search": {
"queries": "disk_index_sample_query_10pts.fbin",
"groundtruth": "disk_index_10pts_idx_uint32_truth_search_res.bin",
"reps": 1,
"num_threads": [
2
],
"runs": [
{
"search_n": 10,
"search_l": [
20,
40
],
"recall_k": 10
}
]
"num_threads": 2,
"search_l": 40,
"search_n": 10,
"recall_k": 10
},
"runbook_params": {
"runbook_path": "example_runbook.yaml",
Expand Down
Loading
Loading