[−][src]Enum rust2vec::storage::StorageViewWrap
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]
fn view(&self) -> ArrayView2<f32>
[src]
impl From<MmapArray> for StorageViewWrap
[src]
impl From<NdArray> for StorageViewWrap
[src]
Auto Trait Implementations
impl Send for StorageViewWrap
impl Sync for StorageViewWrap
Blanket Implementations
impl<S> Quantize for S where
S: StorageView,
[src]
S: StorageView,
fn quantize_using<T, R>(
&Self,
usize,
u32,
usize,
usize,
bool,
&mut R
) -> QuantizedArray where
R: Rng,
T: TrainPQ<f32>,
[src]
&Self,
usize,
u32,
usize,
usize,
bool,
&mut R
) -> QuantizedArray where
R: Rng,
T: TrainPQ<f32>,
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]
&self,
n_subquantizers: usize,
n_subquantizer_bits: u32,
n_iterations: usize,
n_attempts: usize,
normalize: bool
) -> QuantizedArray where
T: TrainPQ<f32>,
Quantize the embedding matrix. Read more
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,