From fcd28a5edeaf65bd066be88a14d1029d118a36d4 Mon Sep 17 00:00:00 2001 From: osmarks Date: Sat, 18 Jan 2025 17:09:44 +0000 Subject: [PATCH] add missing files --- diskann/src/vector.rs | 8 ++++---- frontend_config.json | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/diskann/src/vector.rs b/diskann/src/vector.rs index 7196164..0ed93e1 100644 --- a/diskann/src/vector.rs +++ b/diskann/src/vector.rs @@ -316,7 +316,7 @@ pub struct ProductQuantizer { } // chunk * centroid_index -pub struct DistanceLUT(Vec); +pub struct QueryLUT(Vec); impl ProductQuantizer { pub fn apply_transform(&self, x: &[f32]) -> Vec { @@ -366,7 +366,7 @@ impl ProductQuantizer { } // not particularly performance-sensitive right now; do unbatched - pub fn preprocess_query(&self, query: &[f32]) -> DistanceLUT { + pub fn preprocess_query(&self, query: &[f32]) -> QueryLUT { let transformed = self.apply_transform(query); let n_chunks = self.n_dims / self.n_dims_per_code; let n_centroids = self.centroids.len() / self.n_dims; @@ -382,11 +382,11 @@ impl ProductQuantizer { } } - DistanceLUT(lut) + QueryLUT(lut) } // compute dot products of query against product-quantized vectors - pub fn asymmetric_dot_product(&self, query: &DistanceLUT, pq_vectors: &[u8]) -> Vec { + pub fn asymmetric_dot_product(&self, query: &QueryLUT, pq_vectors: &[u8]) -> Vec { let n_chunks = self.n_dims / self.n_dims_per_code; let n_vectors = pq_vectors.len() / n_chunks; let mut scores = vec![0.0; n_vectors]; diff --git a/frontend_config.json b/frontend_config.json index 3406307..0d5b164 100644 --- a/frontend_config.json +++ b/frontend_config.json @@ -1,5 +1,5 @@ { - "backend_url": "http://localhost:1707/", - "image_path": "http://localhost:7858/", - "thumb_path": "http://localhost:7857/" -} \ No newline at end of file + "backend_url": "http://localhost:5601/", + "image_path": "", + "thumb_path": null +}