pub struct GraphTensor<S: Shape, T: DType, D: Dev> { /* private fields */ }
Expand description
A tensor representing an intermediary result of a graph. Performing operations on this tensor will not cause any computations.
Implementations§
Source§impl<const B: usize, const M: usize, const K: usize, T: DType, D: Dev> GraphTensor<R3<B, M, K>, T, D>
impl<const B: usize, const M: usize, const K: usize, T: DType, D: Dev> GraphTensor<R3<B, M, K>, T, D>
pub fn matmul<const N: usize>( self, rhs: GraphTensor<R3<B, K, N>, T, D>, ) -> GraphTensor<R3<B, M, N>, T, D>
Sourcepub fn matmul_axpby<const N: usize>(
self,
rhs: GraphTensor<R3<B, K, N>, T, D>,
out: GraphTensor<R3<B, M, N>, T, D>,
alpha: T,
beta: T,
) -> GraphTensor<R3<B, M, N>, T, D>
pub fn matmul_axpby<const N: usize>( self, rhs: GraphTensor<R3<B, K, N>, T, D>, out: GraphTensor<R3<B, M, N>, T, D>, alpha: T, beta: T, ) -> GraphTensor<R3<B, M, N>, T, D>
out = out * alpha + beta * lhs * rhs
Source§impl<S: Shape, T: DType, D: Dev> GraphTensor<S, T, D>
impl<S: Shape, T: DType, D: Dev> GraphTensor<S, T, D>
Source§impl<S: Shape, T: DType, D: Dev> GraphTensor<S, T, D>
impl<S: Shape, T: DType, D: Dev> GraphTensor<S, T, D>
Trait Implementations§
Source§impl<S: Clone + Shape, T: Clone + DType, D: Clone + Dev> Clone for GraphTensor<S, T, D>
impl<S: Clone + Shape, T: Clone + DType, D: Clone + Dev> Clone for GraphTensor<S, T, D>
Source§fn clone(&self) -> GraphTensor<S, T, D>
fn clone(&self) -> GraphTensor<S, T, D>
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl<S, T, D> Freeze for GraphTensor<S, T, D>
impl<S, T, D> !RefUnwindSafe for GraphTensor<S, T, D>
impl<S, T, D> !Send for GraphTensor<S, T, D>
impl<S, T, D> !Sync for GraphTensor<S, T, D>
impl<S, T, D> Unpin for GraphTensor<S, T, D>
impl<S, T, D> !UnwindSafe for GraphTensor<S, T, D>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more