Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change raft-ann-bench package name to raft_ann_bench #671

Merged
merged 1 commit into from
May 24, 2024
Merged
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
14 changes: 7 additions & 7 deletions context/raft-ann-bench/get_datasets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ set -eo pipefail

export CONDA_PREFIX=/opt/conda

python -m raft-ann-bench.get_dataset --dataset deep-image-96-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft-ann-bench.get_dataset --dataset fashion-mnist-784-euclidean --dataset-path /home/rapids/preloaded_datasets
python -m raft-ann-bench.get_dataset --dataset glove-50-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft-ann-bench.get_dataset --dataset glove-100-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft-ann-bench.get_dataset --dataset mnist-784-euclidean --dataset-path /home/rapids/preloaded_datasets
python -m raft-ann-bench.get_dataset --dataset nytimes-256-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft-ann-bench.get_dataset --dataset sift-128-euclidean --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset deep-image-96-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset fashion-mnist-784-euclidean --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset glove-50-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset glove-100-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset mnist-784-euclidean --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset nytimes-256-angular --normalize --dataset-path /home/rapids/preloaded_datasets
python -m raft_ann_bench.get_dataset --dataset sift-128-euclidean --dataset-path /home/rapids/preloaded_datasets
8 changes: 4 additions & 4 deletions context/raft-ann-bench/run_benchmark.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export RUN_ARGS=$3
export PLOT_ARGS=$4

# (1) prepare dataset.
python -m raft-ann-bench.get_dataset ${DATASET_ARG} ${GET_DATASET_ARGS} --dataset-path /data/benchmarks/datasets
python -m raft_ann_bench.get_dataset ${DATASET_ARG} ${GET_DATASET_ARGS} --dataset-path /data/benchmarks/datasets

if [[ "$DATASET_ARG" == *"angular"* ]]; then
export DATASET_ARG=${DATASET_ARG/angular/inner}
Expand All @@ -30,10 +30,10 @@ if [[ "$DATASET_ARG" == *"angular"* ]]; then
fi

# (2) build and search index
python -m raft-ann-bench.run ${DATASET_ARG} --dataset-path /data/benchmarks/datasets --force ${RUN_ARGS}
python -m raft_ann_bench.run ${DATASET_ARG} --dataset-path /data/benchmarks/datasets --force ${RUN_ARGS}

# (3) export data
python -m raft-ann-bench.data_export ${DATASET_ARG} --dataset-path /data/benchmarks/datasets
python -m raft_ann_bench.data_export ${DATASET_ARG} --dataset-path /data/benchmarks/datasets

# Extract the algorithms from the run command to use in the plot command
ALGOS=$(grep -oP "algorithms\s+\K(\w+,?\w+)" <<< "$RUN_ARGS")
Expand All @@ -44,4 +44,4 @@ fi
# (4) plot results
mkdir -p /data/benchmarks/datasets/result
cd /data/benchmarks/datasets/result
python -m raft-ann-bench.plot ${DATASET_ARG} ${ALGOS} ${PLOT_ARGS} --dataset-path /data/benchmarks/datasets --build --search
python -m raft_ann_bench.plot ${DATASET_ARG} ${ALGOS} ${PLOT_ARGS} --dataset-path /data/benchmarks/datasets --build --search
8 changes: 4 additions & 4 deletions context/raft-ann-bench/run_benchmarks_preloaded_datasets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ case $DATASET_ARG in
export DATASET_PATH=/home/rapids/preloaded_datasets ;;
*)
export DATASET_PATH=/data/benchmarks/datasets
python -m raft-ann-bench.get_dataset ${DATASET_ARG} ${GET_DATASET_ARGS} --dataset-path $DATASET_PATH ;;
python -m raft_ann_bench.get_dataset ${DATASET_ARG} ${GET_DATASET_ARGS} --dataset-path $DATASET_PATH ;;
esac

if [[ "$DATASET_ARG" == *"angular"* ]]; then
Expand All @@ -37,10 +37,10 @@ if [[ "$DATASET_ARG" == *"angular"* ]]; then
fi

# (2) build and search index
python -m raft-ann-bench.run ${DATASET_ARG} --dataset-path $DATASET_PATH ${RUN_ARGS}
python -m raft_ann_bench.run ${DATASET_ARG} --dataset-path $DATASET_PATH ${RUN_ARGS}

# (3) export data
python -m raft-ann-bench.data_export ${DATASET_ARG} --dataset-path $DATASET_PATH
python -m raft_ann_bench.data_export ${DATASET_ARG} --dataset-path $DATASET_PATH

# Extract the algorithms from the run command to use in the plot command
ALGOS=$(grep -oP "algorithms\s+\K(\w+,?\w+)" <<< "$RUN_ARGS")
Expand All @@ -51,4 +51,4 @@ fi
# (4) plot results
mkdir -p $DATASET_PATH/result
cd $DATASET_PATH/result
python -m raft-ann-bench.plot ${DATASET_ARG} ${ALGOS} ${PLOT_ARGS} --dataset-path $DATASET_PATH
python -m raft_ann_bench.plot ${DATASET_ARG} ${ALGOS} ${PLOT_ARGS} --dataset-path $DATASET_PATH
Loading