[][src]Struct ndarray_einsum_beta::EinsumPath

pub struct EinsumPath<A> {
    pub contraction_order: ContractionOrder,
    pub steps: EinsumPathSteps<A>,
}

An EinsumPath, returned by einsum_path, represents a fully-prepared plan to perform a tensor contraction.

It contains the order in which the input tensors should be contracted with one another or with one of the previous intermediate results, and for each step in the path, how to perform the pairwise contraction. For example, two tensors might be contracted with one another by computing the Hadamard (element-wise) product of the tensors, while a different pair might be contracted by performing a matrix multiplication. The contractions that will be performed are fully specified within the EinsumPath.

Fields

contraction_order: ContractionOrder

The order in which tensors should be paired off and contracted with one another

steps: EinsumPathSteps<A>

The details of the contractions to be performed

Methods

impl<A> EinsumPath<A>[src]

pub fn new(sc: &SizedContraction) -> Self[src]

pub fn from_path(contraction_order: &ContractionOrder) -> Self[src]

impl<A> EinsumPath<A>[src]

pub fn contract_operands(&self, operands: &[&dyn ArrayLike<A>]) -> ArrayD<A> where
    A: Clone + LinalgScalar
[src]

Trait Implementations

impl<A> Debug for EinsumPath<A>[src]

Auto Trait Implementations

impl<A> !Send for EinsumPath<A>

impl<A> !Sync for EinsumPath<A>

Blanket Implementations

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

impl<T> From<T> for 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.

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

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

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