#[repr(C)]pub struct cuvsHnswAceParams {
pub npartitions: usize,
pub build_dir: *const c_char,
pub use_disk: bool,
pub max_host_memory_gb: f64,
pub max_gpu_memory_gb: f64,
}Expand description
Parameters for ACE (Augmented Core Extraction) graph build for HNSW. ACE enables building indexes for datasets too large to fit in GPU memory by:
- Partitioning the dataset in core and augmented partitions using balanced k-means
- Building sub-indexes for each partition independently
- Concatenating sub-graphs into a final unified index
Fields§
§npartitions: usizeNumber of partitions for ACE partitioned build.
When set to 0 (default), the number of partitions is automatically derived based on available host and GPU memory to maximize partition size while ensuring the build fits in memory.
Small values might improve recall but potentially degrade performance and increase memory usage. The partition size is on average 2 * (n_rows / npartitions) * dim * sizeof(T). 2 is because of the core and augmented vectors. Please account for imbalance in the partition sizes (up to 3x in our tests).
If the specified number of partitions results in partitions that exceed available memory, the value will be automatically increased to fit memory constraints and a warning will be issued.
build_dir: *const c_charDirectory to store ACE build artifacts (e.g., KNN graph, optimized graph).
Used when use_disk is true or when the graph does not fit in memory.
use_disk: boolWhether to use disk-based storage for ACE build. When true, enables disk-based operations for memory-efficient graph construction.
max_host_memory_gb: f64Maximum host memory to use for ACE build in GiB. When set to 0 (default), uses available host memory. Useful for testing or when running alongside other memory-intensive processes.
max_gpu_memory_gb: f64Maximum GPU memory to use for ACE build in GiB. When set to 0 (default), uses available GPU memory. Useful for testing or when running alongside other memory-intensive processes.
Trait Implementations§
Source§impl Clone for cuvsHnswAceParams
impl Clone for cuvsHnswAceParams
Source§fn clone(&self) -> cuvsHnswAceParams
fn clone(&self) -> cuvsHnswAceParams
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more