Skip to content

Commit

Permalink
Impl new methods of Index trait
Browse files Browse the repository at this point in the history
  • Loading branch information
ava57r committed Jun 13, 2021
1 parent e3ce68e commit d176baa
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/index/pretransform.rs
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,16 @@ impl<I> Index for PreTransformIndexImpl<I> {
Ok(n_removed)
}
}

fn verbose(&self) -> bool {
unsafe { faiss_Index_verbose(self.inner) != 0 }
}

fn set_verbose(&mut self, value: bool) {
unsafe {
faiss_Index_set_verbose(self.inner, std::os::raw::c_int::from(value));
}
}
}

impl<I> PreTransformIndexImpl<I> {
Expand Down

0 comments on commit d176baa

Please sign in to comment.