pub struct EmbeddingManager { /* private fields */ }
Implementations§
Source§impl EmbeddingManager
impl EmbeddingManager
pub fn new(max_speakers: usize) -> Self
Sourcepub fn search_speaker(
&mut self,
embedding: Vec<f32>,
threshold: f32,
) -> Option<usize>
pub fn search_speaker( &mut self, embedding: Vec<f32>, threshold: f32, ) -> Option<usize>
Search or create speaker
pub fn get_best_speaker_match(&mut self, embedding: Vec<f32>) -> Result<usize>
pub fn get_all_speakers(&self) -> &HashMap<usize, Array1<f32>>
Trait Implementations§
Source§impl Clone for EmbeddingManager
impl Clone for EmbeddingManager
Source§fn clone(&self) -> EmbeddingManager
fn clone(&self) -> EmbeddingManager
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for EmbeddingManager
impl RefUnwindSafe for EmbeddingManager
impl Send for EmbeddingManager
impl Sync for EmbeddingManager
impl Unpin for EmbeddingManager
impl UnwindSafe for EmbeddingManager
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more