[][src]Enum rust2vec::storage::StorageViewWrap

pub enum StorageViewWrap {
    MmapArray(MmapArray),
    NdArray(NdArray),
}

Wrapper for storage types that implement views.

This type covers the subset of storage types that implement StorageView. See the StorageWrap type for more information.

Variants

MmapArray(MmapArray)NdArray(NdArray)

Trait Implementations

impl Storage for StorageViewWrap[src]

impl StorageView for StorageViewWrap[src]

impl From<MmapArray> for StorageViewWrap[src]

impl From<NdArray> for StorageViewWrap[src]

Auto Trait Implementations

Blanket Implementations

impl<S> Quantize for S where
    S: StorageView
[src]

fn quantize_using<T, R>(
    &Self,
    usize,
    u32,
    usize,
    usize,
    bool,
    &mut R
) -> QuantizedArray where
    R: Rng,
    T: TrainPQ<f32>, 
[src]

Quantize the embedding matrix.

This method trains a quantizer for the embedding matrix and then quantizes the matrix using this quantizer.

fn quantize<T>(
    &self,
    n_subquantizers: usize,
    n_subquantizer_bits: u32,
    n_iterations: usize,
    n_attempts: usize,
    normalize: bool
) -> QuantizedArray where
    T: TrainPQ<f32>, 
[src]

Quantize the embedding matrix. Read more

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

impl<T> From for T[src]

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

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

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

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

The type returned in the event of a conversion error.