Skip to main content

SVEStrategy

Trait SVEStrategy 

Source
pub trait SVEStrategy<T: CustomNumeric> {
    // Required methods
    fn matrices(&self) -> Vec<Mat<T>>;
    fn postprocess(
        &self,
        u_list: Vec<Mat<T>>,
        s_list: Vec<Vec<T>>,
        v_list: Vec<Mat<T>>,
    ) -> Result<SVEResult, Error>;

    // Provided method
    fn blocks(&self) -> Vec<KernelBlock<'_, T>>
       where T: Send + Sync + 'static { ... }
}
Expand description

Trait for SVE computation strategies

Required Methods§

Source

fn matrices(&self) -> Vec<Mat<T>>

Compute the discretized matrices for SVD

Source

fn postprocess( &self, u_list: Vec<Mat<T>>, s_list: Vec<Vec<T>>, v_list: Vec<Mat<T>>, ) -> Result<SVEResult, Error>

Post-process SVD results to create SVEResult

§Errors

The errors of SVEResult::new

Provided Methods§

Source

fn blocks(&self) -> Vec<KernelBlock<'_, T>>
where T: Send + Sync + 'static,

The discretized, weighted kernel blocks to decompose, the matrices of Self::matrices with their entries evaluated on demand

compute_sve decomposes these in double-double by adaptive cross approximation, which reads only a few rows and columns of each (in f64 it decomposes Self::matrices as before). The default forms the matrices; the strategies of this crate evaluate the kernel lazily.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<T, K> SVEStrategy<T> for CentrosymmSVE<T, K>
where T: CustomNumeric + Send + Sync + Clone + 'static, K: ReducedKernel + SVEKernel + Clone, K::SVEHintsType<T>: SVEHints<T> + Clone,

Source§

impl<T, K> SVEStrategy<T> for NonCentrosymmSVE<T, K>
where T: CustomNumeric + Send + Sync + Clone + 'static, K: AbstractKernel + SVEKernel + Clone, K::SVEHintsType<T>: SVEHints<T> + Clone,