View source: R/benchmark_interface.R
| benchmark_annoy_recall_suite | R Documentation |
Run a grid of n_trees and search_k settings on the same benchmark
dataset, optionally recording recall against the exact bigKNN Euclidean
baseline.
benchmark_annoy_recall_suite(
x = NULL,
query = NULL,
n_ref = 2000L,
n_query = 200L,
n_dim = 20L,
k = 10L,
n_trees = c(10L, 50L, 100L),
search_k = c(-1L, 1000L, 5000L),
metric = "euclidean",
seed = 42L,
build_seed = seed,
build_threads = -1L,
block_size = annoy_default_block_size(),
backend = getOption("bigANNOY.backend", "cpp"),
exact = TRUE,
filebacked = FALSE,
path_dir = tempdir(),
keep_files = FALSE,
output_path = NULL,
load_mode = "eager"
)
x |
Optional benchmark reference input. Supply |
query |
Optional benchmark query input. Supply |
n_ref |
Number of synthetic reference rows to generate when |
n_query |
Number of synthetic query rows to generate when |
n_dim |
Number of synthetic columns to generate when |
k |
Number of neighbours to return. |
n_trees |
Integer vector of Annoy tree counts to benchmark. |
search_k |
Integer vector of Annoy search budgets to benchmark. |
metric |
Annoy metric. One of |
seed |
Random seed used for synthetic data generation and, by default, for the Annoy build seed. |
build_seed |
Optional Annoy build seed. Defaults to |
build_threads |
Native Annoy build-thread setting. |
block_size |
Build/search block size. |
backend |
Requested bigANNOY backend. |
exact |
Logical flag controlling whether to benchmark the exact
Euclidean baseline with |
filebacked |
Logical flag; if |
path_dir |
Directory where temporary Annoy and optional file-backed benchmark files should be written. |
keep_files |
Logical flag; if |
output_path |
Optional CSV path where the benchmark summary should be written. |
load_mode |
Whether the benchmarked index should be returned
metadata-only until first search ( |
A list with a summary data frame containing one row per
(n_trees, search_k) configuration.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.