pub struct SuperBitSimHash<H, S, const L: usize>where
H: SimHasher<T = u64>,
S: SimHashBits,{ /* private fields */ }Implementations§
Source§impl<H, S, const L: usize> SuperBitSimHash<H, S, L>where
H: SimHasher<T = u64>,
S: SimHashBits,
impl<H, S, const L: usize> SuperBitSimHash<H, S, L>where
H: SimHasher<T = u64>,
S: SimHashBits,
pub fn new(hasher: H, r: usize, seed: u64) -> Self
Sourcepub fn create_signature<U>(&self, iter: impl Iterator<Item = U>) -> Swhere
U: Hash,
pub fn create_signature<U>(&self, iter: impl Iterator<Item = U>) -> Swhere
U: Hash,
Unweighted items: treat each item as weight 1.0 (see classic SimHash).
Sourcepub fn create_signature_weighted<U>(
&self,
iter: impl Iterator<Item = (U, f32)>,
) -> Swhere
U: Hash,
pub fn create_signature_weighted<U>(
&self,
iter: impl Iterator<Item = (U, f32)>,
) -> Swhere
U: Hash,
Weighted variant (useful for TF/IDF or MS intensities after L2 norm). Weighted variant (useful for TF/IDF or MS intensities after L2 norm).
Auto Trait Implementations§
impl<H, S, const L: usize> Freeze for SuperBitSimHash<H, S, L>where
H: Freeze,
impl<H, S, const L: usize> RefUnwindSafe for SuperBitSimHash<H, S, L>where
H: RefUnwindSafe,
S: RefUnwindSafe,
impl<H, S, const L: usize> Send for SuperBitSimHash<H, S, L>
impl<H, S, const L: usize> Sync for SuperBitSimHash<H, S, L>
impl<H, S, const L: usize> Unpin for SuperBitSimHash<H, S, L>
impl<H, S, const L: usize> UnwindSafe for SuperBitSimHash<H, S, L>where
H: UnwindSafe,
S: UnwindSafe,
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