SingletonContractor

Trait SingletonContractor 

Source
pub trait SingletonContractor<A>: Debug {
    // Required method
    fn contract_singleton<'a, 'b>(
        &self,
        tensor: &'b ArrayViewD<'a, A>,
    ) -> ArrayD<A>
       where A: Clone + LinalgScalar,
             'a: 'b;
}
Expand description

let new_array = obj.contract_singleton(tensor_view);

All singleton contractions should implement this trait. It returns a new owned ArrayD.

Required Methods§

Source

fn contract_singleton<'a, 'b>(&self, tensor: &'b ArrayViewD<'a, A>) -> ArrayD<A>
where A: Clone + LinalgScalar, 'a: 'b,

Implementors§