Tune the words prefixes threshold to compute for 1/1000 instead

This commit is contained in:
Kerollmops 2021-03-03 11:25:36 +01:00
parent f376c6a728
commit 07784c8990
No known key found for this signature in database
GPG Key ID: 92ADA4E935E71FA4
3 changed files with 3 additions and 2 deletions

1
Cargo.lock generated
View File

@ -866,6 +866,7 @@ dependencies = [
"anyhow", "anyhow",
"byte-unit", "byte-unit",
"heed", "heed",
"jemallocator",
"milli", "milli",
"stderrlog", "stderrlog",
"structopt", "structopt",

View File

@ -598,7 +598,7 @@ fn export_documents(index: &Index, rtxn: &heed::RoTxn, internal_ids: Vec<u32>) -
let fields_ids_map = index.fields_ids_map(rtxn)?; let fields_ids_map = index.fields_ids_map(rtxn)?;
let displayed_fields: Vec<_> = fields_ids_map.iter().map(|(id, _name)| id).collect(); let displayed_fields: Vec<_> = fields_ids_map.iter().map(|(id, _name)| id).collect();
let iter: Box<Iterator<Item = _>> = if internal_ids.is_empty() { let iter: Box<dyn Iterator<Item = _>> = if internal_ids.is_empty() {
Box::new(index.documents.iter(rtxn)?.map(|result| { Box::new(index.documents.iter(rtxn)?.map(|result| {
result.map(|(_id, obkv)| obkv) result.map(|(_id, obkv)| obkv)
})) }))

View File

@ -41,7 +41,7 @@ impl<'t, 'u, 'i> WordsPrefixes<'t, 'u, 'i> {
chunk_fusing_shrink_size: None, chunk_fusing_shrink_size: None,
max_nb_chunks: None, max_nb_chunks: None,
max_memory: None, max_memory: None,
threshold: 0.01, // 1% threshold: 0.1 / 100.0, // .01%
max_prefix_length: 4, max_prefix_length: 4,
_update_id: update_id, _update_id: update_id,
} }