pub trait ContractBuilder<'a, T, Sa, Sb, La, Lb>{
// Required methods
fn scale(self, factor: T) -> Self;
fn eval(self) -> Array<T, DynRank>;
fn write<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>);
fn add_to<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>);
fn add_to_scaled<Sc: Shape, Lc: Layout>(
self,
c: &mut Slice<T, Sc, Lc>,
beta: T,
);
}Expand description
Builder interface for configuring tensor contraction operations
Required Methods§
Sourcefn write<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>)
fn write<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>)
Overwrites the provided slice with the result.
Sourcefn add_to<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>)
fn add_to<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>)
Adds the result to the provided slice.
Sourcefn add_to_scaled<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>, beta: T)
fn add_to_scaled<Sc: Shape, Lc: Layout>(self, c: &mut Slice<T, Sc, Lc>, beta: T)
Adds the result to the provided slice after scaling the slice by beta
(i.e. C := beta * C + result).
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".