TensorLinalgContextFor

Trait TensorLinalgContextFor 

Source
pub trait TensorLinalgContextFor<T: KernelLinalgScalar>: TensorSemiringContextFor<Standard<T>> {
    type Backend: TensorLinalgPrims<T, Context = Self>;
}
Expand description

Maps a context type to its tensor-level linalg backend.

§Examples

use tenferro_linalg_prims::backend::TensorLinalgContextFor;

fn accepts_ctx<T, C>(_ctx: &mut C)
where
    T: tenferro_linalg_prims::KernelLinalgScalar,
    C: TensorLinalgContextFor<T>,
{
}

Required Associated Types§

Source

type Backend: TensorLinalgPrims<T, Context = Self>

The backend associated with this context type.

Implementations on Foreign Types§

Source§

impl<T> TensorLinalgContextFor<T> for CpuContext

Source§

impl<T: KernelLinalgScalar> TensorLinalgContextFor<T> for RocmContext

Source§

impl<T: CudaLinalgScalar> TensorLinalgContextFor<T> for CudaContext

Implementors§