Skip to content

Commit

Permalink
add big bench experiment runner
Browse files Browse the repository at this point in the history
  • Loading branch information
blaise-muhirwa committed Nov 23, 2023
1 parent 789e7f7 commit e3c5794
Show file tree
Hide file tree
Showing 13 changed files with 308 additions and 296 deletions.
23 changes: 23 additions & 0 deletions experiments/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@


# Run the yandex-deep benchmark and log everything to a logs.txt file
yandex-deep-bench: install-lib
poetry run python run-big-bench.py \
--dataset path/to/yandex-deep.350.fbin \
--queries path/to/yandex-deep-queries.fbin \
--gtruth path/to/yandex-ground-truth \
--metric l2 \
logs.txt 2>&1


# Install all dependencies including flatnav
install-lib: generate-wheel
poetry add ../flatnav_python/dist/*.whl
poetry install --no-root

# This will generate the wheel for flatnav and put it in
# ../flatnav_python/dist
generate-wheel:
pwd
cd .. && cd flatnav_python && ./install_flatnav.sh

222 changes: 0 additions & 222 deletions experiments/big-ann/run_bigann.py

This file was deleted.

2 changes: 1 addition & 1 deletion experiments/evaluate_faiss.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ def train_hnsw_index(

return index


def main(
train_dataset: np.ndarray,
queries: np.ndarray,
Expand Down Expand Up @@ -219,4 +220,3 @@ def main(
ef_search_params=ef_searches,
num_node_links=num_node_links,
)

2 changes: 1 addition & 1 deletion experiments/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ dvc = "^3.28.0"
black = "^23.11.0"
numpy = "^1.26.1"
faiss-cpu = "^1.7.4"
flatnav = {path = "../flatnav_python/dist/flatnav-0.0.1-cp310-cp310-linux_x86_64.whl"}
flatnav = {path = "../flatnav_python/dist/flatnav-0.0.1-cp311-cp311-macosx_13_0_arm64.whl"}


[build-system]
Expand Down
Loading

0 comments on commit e3c5794

Please sign in to comment.