[][src]Struct space::Hamming

pub struct Hamming<T>(pub T);

Any data contained in this struct is treated such that all of the bits of the data are each separate dimensions that can be of length 0 or 1. This is referred to as hamming space. This leads to all Lp spaces being equal and all distances being no larger than the number of bits of the data.

This is typically used to perform searches on data that was binarized using hyperplane comparisons on high dimensional floating-point features or data built on a series of binary comparisons. Hamming distance is incredibly fast to compute. Hamming space can be difficult to search because the amount of equidistant points is high (see "Thick Boundaries in Binary Space and Their Influence on Nearest-Neighbor Search") and they can quickly grow in dimensionality.

Trait Implementations

impl<T: Clone> Clone for Hamming<T>[src]

impl<T: Copy> Copy for Hamming<T>[src]

impl<T: Debug> Debug for Hamming<T>[src]

impl<T: Eq> Eq for Hamming<T>[src]

impl<T: Hash> Hash for Hamming<T>[src]

impl MetricPoint for Hamming<u8>[src]

impl MetricPoint for Hamming<u16>[src]

impl MetricPoint for Hamming<u32>[src]

impl MetricPoint for Hamming<u64>[src]

impl MetricPoint for Hamming<u128>[src]

impl<T: PartialEq> PartialEq<Hamming<T>> for Hamming<T>[src]

impl<T> StructuralEq for Hamming<T>[src]

impl<T> StructuralPartialEq for Hamming<T>[src]

Auto Trait Implementations

impl<T> Send for Hamming<T> where
    T: Send

impl<T> Sync for Hamming<T> where
    T: Sync

impl<T> Unpin for Hamming<T> where
    T: Unpin

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.