pub struct VoiceprintTracker<'a, E, S = NoSegmenter> { /* private fields */ }Available on crate feature
silero and non-target_family=wasm only.Expand description
Cuts one recording into turns and judges each one. The diarizer scores whose voice a window is. The segmenter, when there is one, checks a speaker change inside a turn before the turn splits, which owner-only admission needs.
Implementations§
Source§impl<'a, E: Embedder> VoiceprintTracker<'a, E>
impl<'a, E: Embedder> VoiceprintTracker<'a, E>
Source§impl<'a, E: Embedder, S: Segmenter> VoiceprintTracker<'a, E, S>
impl<'a, E: Embedder, S: Segmenter> VoiceprintTracker<'a, E, S>
Sourcepub fn owner_only(
diarizer: &'a mut Diarizer<E>,
segmenter: S,
at: u64,
) -> Result<Self, OwnerTrackingError>
pub fn owner_only( diarizer: &'a mut Diarizer<E>, segmenter: S, at: u64, ) -> Result<Self, OwnerTrackingError>
A tracker that can admit only the owner’s words: it needs an enrolled owner, and a segmenter to check speaker changes.
Trait Implementations§
Source§impl<E: Embedder, S: Segmenter> SpeakerTracker for VoiceprintTracker<'_, E, S>
impl<E: Embedder, S: Segmenter> SpeakerTracker for VoiceprintTracker<'_, E, S>
Source§fn hear(&mut self, speech: &SpeechMap, audio: &[f32])
fn hear(&mut self, speech: &SpeechMap, audio: &[f32])
Takes the audio after what it has heard.
Source§fn skip_to(&mut self, speech: &SpeechMap, at: u64)
fn skip_to(&mut self, speech: &SpeechMap, at: u64)
Gives up on the audio before
at, which it will never hear.fn timeline(&self) -> &Timeline
Source§fn forget_before(&mut self, at: u64) -> u64
fn forget_before(&mut self, at: u64) -> u64
Forgets the timeline before
at, or before the open turn’s start
when that comes first. Returns how far the speech map may be
forgotten: never past what the tracker still reads from it.Auto Trait Implementations§
impl<'a, E, S = NoSegmenter> !UnwindSafe for VoiceprintTracker<'a, E, S>
impl<'a, E, S> Freeze for VoiceprintTracker<'a, E, S>
impl<'a, E, S> RefUnwindSafe for VoiceprintTracker<'a, E, S>
impl<'a, E, S> Send for VoiceprintTracker<'a, E, S>
impl<'a, E, S> Sync for VoiceprintTracker<'a, E, S>
impl<'a, E, S> Unpin for VoiceprintTracker<'a, E, S>
impl<'a, E, S> UnsafeUnpin for VoiceprintTracker<'a, E, S>
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