mirror of
https://github.com/osmarks/meme-search-engine.git
synced 2025-04-06 18:56:57 +00:00
remove vestigal r_cap
This commit is contained in:
parent
8ce51bcb56
commit
087419f470
@ -55,7 +55,6 @@ impl IndexGraph {
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
pub struct IndexBuildConfig {
|
||||
pub r: usize,
|
||||
pub r_cap: usize,
|
||||
pub l: usize,
|
||||
pub maxc: usize,
|
||||
pub alpha: i64
|
||||
@ -354,7 +353,7 @@ pub fn augment_bipartite(rng: &mut Rng, graph: &mut IndexGraph, query_knns: Vec<
|
||||
sigmas.into_par_iter().for_each_init(|| rng.lock().unwrap().fork(), |rng, sigma_i| {
|
||||
let mut neighbours = graph.out_neighbours_mut(sigma_i);
|
||||
let mut i = 0;
|
||||
while neighbours.len() < config.r_cap && i < 100 {
|
||||
while neighbours.len() < config.r && i < 100 {
|
||||
let query_neighbour = *rng.choice(&query_knns[sigma_i as usize]).unwrap();
|
||||
let projected_neighbour = *rng.choice(&query_knns_bwd[query_neighbour as usize]).unwrap();
|
||||
if !neighbours.contains(&projected_neighbour) {
|
||||
|
@ -60,7 +60,6 @@ fn main() -> Result<()> {
|
||||
|
||||
let mut config = IndexBuildConfig {
|
||||
r: 64,
|
||||
r_cap: 64,
|
||||
l: 192,
|
||||
maxc: 750,
|
||||
alpha: 65200,
|
||||
@ -93,7 +92,6 @@ fn main() -> Result<()> {
|
||||
|
||||
let mut config = IndexBuildConfig {
|
||||
r: 64,
|
||||
r_cap: 64,
|
||||
l: 50,
|
||||
alpha: 65536,
|
||||
maxc: 0,
|
||||
|
@ -42,7 +42,6 @@ fn main() -> Result<()> {
|
||||
|
||||
let mut config = IndexBuildConfig {
|
||||
r: 64,
|
||||
r_cap: 64,
|
||||
l: 200,
|
||||
maxc: 750,
|
||||
alpha: 65300
|
||||
@ -54,7 +53,7 @@ fn main() -> Result<()> {
|
||||
length: original_ids.len()
|
||||
};
|
||||
|
||||
let mut graph = IndexGraph::empty(original_ids.len(), config.r_cap);
|
||||
let mut graph = IndexGraph::empty(original_ids.len(), config.r);
|
||||
|
||||
{
|
||||
//let _timer = Timer::new("project bipartite");
|
||||
|
Loading…
x
Reference in New Issue
Block a user