pub struct Matrix<M, S> { /* private fields */ }

Implementations§

source§

impl<T, M> Matrix<M, Dim0>
where T: Num, M: Memory<Item = T>,

source

pub fn scalar(scalar: T) -> Self
where M: Owned<Item = T>,

source

pub fn get_value(&self) -> T

source

pub fn set_value(&mut self, value: T)
where M: ViewMut<Item = T>,

source§

impl<M, S> Matrix<M, S>

source

pub fn into_dyn_dim(self) -> Matrix<M, DimDyn>
where M: Memory, S: DimTrait,

Trait Implementations§

source§

impl<T: Num, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, D1: DimTrait, D2: DimTrait> Add<Matrix<M1, D1>> for Matrix<M2, D2>

§

type Output = Matrix<OwnedMem<T>, D2>

The resulting type after applying the + operator.
source§

fn add(self, rhs: Matrix<M1, D1>) -> Self::Output

Performs the + operation. Read more
source§

impl<T: Num, M: ToViewMemory<Item = T> + ToOwnedMemory, D: DimTrait> Add<T> for Matrix<M, D>

§

type Output = Matrix<<M as ToOwnedMemory>::Owned, D>

The resulting type after applying the + operator.
source§

fn add(self, rhs: T) -> Self::Output

Performs the + operation. Read more
source§

impl<M: ViewMut, S: DimTrait> AsMutPtr for Matrix<M, S>

source§

fn as_mut_ptr(&mut self) -> *mut Self::Item

source§

impl<M: Memory, S: DimTrait> AsPtr for Matrix<M, S>

source§

fn as_ptr(&self) -> *const Self::Item

source§

impl<T, M, D> Asum<T> for Matrix<M, D>
where T: Num, M: ToViewMemory<Item = T>, D: DimTrait,

source§

fn asum(self) -> M::Item

source§

impl<T: Num, M: Memory<Item = T>, D: DimTrait> BlasMatrix for Matrix<M, D>

§

type Blas = <M as Memory>::Blas

source§

impl<'a, T: Num> Broadcast<T> for Matrix<ViewMutMem<'a, T>, DimDyn>

source§

fn broadcast(&mut self, source: &Matrix<ViewMem<'_, T>, DimDyn>)

source§

impl<T: Num, SM: ToViewMemory<Item = T>, D: DimTrait> Clip<T> for Matrix<SM, D>

source§

fn clip(&self, min: T, max: T) -> Matrix<OwnedMem<T>, Self::Dim>

Creates a new matrix with the values clipped to be within the range [min, max].
source§

impl<T: Num, SM: ToViewMemory + ToViewMutMemory<Item = T>, D: DimTrait> ClipAssign<T> for Matrix<SM, D>

source§

fn clip_assign(self, min: T, max: T)

Clips the values of the matrix to be within the range [min, max].
source§

impl<M: Clone, S: Clone> Clone for Matrix<M, S>

source§

fn clone(&self) -> Matrix<M, S>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<T, V, VM> CopyFrom<Matrix<V, DimDyn>> for Matrix<VM, DimDyn>
where T: Num, VM: ToViewMutMemory<Item = T>, V: ToViewMemory<Item = T>,

source§

fn copy_from(&mut self, rhs: &Matrix<V, DimDyn>)

source§

impl<A, S, D: DimTrait> Debug for Matrix<S, D>
where A: Num + Debug, S: Memory<Item = A> + ToViewMemory,

Format the array using Debug and apply the formatting parameters used to each element.

The array is shown in multiline style.

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de, M, S> Deserialize<'de> for Matrix<M, S>
where M: Deserialize<'de>, S: Deserialize<'de>,

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl<A, S, D: DimTrait> Display for Matrix<S, D>
where A: Num + Display, S: Memory<Item = A> + ToViewMemory,

Format the array using Display and apply the formatting parameters used to each element.

The array is shown in multiline style.

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<T: Num, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, D1: DimTrait, D2: DimTrait> Div<Matrix<M1, D1>> for Matrix<M2, D2>

§

type Output = Matrix<OwnedMem<T>, D2>

The resulting type after applying the / operator.
source§

fn div(self, rhs: Matrix<M1, D1>) -> Self::Output

Performs the / operation. Read more
source§

impl<T: Num, M: ToViewMemory<Item = T> + ToOwnedMemory, D: DimTrait> Div<T> for Matrix<M, D>

§

type Output = Matrix<<M as ToOwnedMemory>::Owned, D>

The resulting type after applying the / operator.
source§

fn div(self, rhs: T) -> Self::Output

Performs the / operation. Read more
source§

impl<T, SM, RM, LM, DS, DR, DL> Dot<Matrix<RM, DR>, Matrix<LM, DL>> for Matrix<SM, DS>
where T: Num, SM: ViewMut<Item = T>, RM: ToViewMemory<Item = T>, LM: ToViewMemory<Item = T>, DS: DimTrait, DR: DimTrait, DL: DimTrait,

source§

fn dot(self, rhs: Matrix<RM, DR>, lhs: Matrix<LM, DL>)

source§

impl<T: Num, M: ToViewMemory<Item = T>> Exp<T> for Matrix<M, DimDyn>

source§

fn exp(&self) -> Matrix<OwnedMem<T>, DimDyn>

source§

impl<T: Num, M: ToViewMutMemory<Item = T>> ExpAssign<T> for Matrix<M, DimDyn>

source§

fn exp_assign<V: ToViewMemory<Item = T>>(&mut self, y: &Matrix<V, DimDyn>)

source§

impl<T, M1, M2, M3, D1, D2, D3> Gemm<Matrix<M1, D1>, Matrix<M2, D2>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D2: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, M3: ViewMut<Item = T>,

source§

fn gemm(self, rhs: Matrix<M1, D1>, lhs: Matrix<M2, D2>)

Performs the General Matrix Multiply (GEMM) operation. Read more
source§

impl<M: Hash, S: Hash> Hash for Matrix<M, S>

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<I: IndexAxisTrait, M: ToViewMemory, D: DimTrait + LessDimTrait> IndexAxis<I> for Matrix<M, D>
where <D as LessDimTrait>::LessDim: DimTrait,

§

type Output<'a> = Matrix<ViewMem<'a, <M as Memory>::Item>, <D as LessDimTrait>::LessDim> where Self: 'a

source§

fn index_axis(&self, index: I) -> Self::Output<'_>

source§

impl<I: IndexAxisTrait, M: ToViewMemory, D: DimTrait> IndexAxisDyn<I> for Matrix<M, D>

§

type Output<'a> = Matrix<ViewMem<'a, <Matrix<M, D> as MatrixBase>::Item>, DimDyn> where Self: 'a

source§

fn index_axis_dyn(&self, index: I) -> Self::Output<'_>

source§

impl<I: IndexAxisTrait, M: ToViewMutMemory, D: DimTrait + LessDimTrait> IndexAxisMut<I> for Matrix<M, D>
where <D as LessDimTrait>::LessDim: DimTrait,

§

type Output<'a> = Matrix<ViewMutMem<'a, <M as Memory>::Item>, <D as LessDimTrait>::LessDim> where Self: 'a

source§

fn index_axis_mut(&mut self, index: I) -> Self::Output<'_>

source§

impl<I: IndexAxisTrait, M: ToViewMutMemory, D: DimTrait> IndexAxisMutDyn<I> for Matrix<M, D>

§

type Output<'a> = Matrix<ViewMutMem<'a, <M as Memory>::Item>, DimDyn> where Self: 'a

source§

fn index_axis_mut_dyn(&mut self, index: I) -> Self::Output<'_>

source§

impl<D: DimTrait, M: Memory> IndexItem for Matrix<M, D>

source§

fn index_item<I: Into<D>>(&self, index: I) -> Self::Item

source§

impl<T: Num, D: DimTrait, VM: ViewMut + Memory<Item = T>> IndexItemAsign for Matrix<VM, D>

source§

fn index_item_asign<I: Into<Self::Dim>>(&mut self, index: I, value: Self::Item)

source§

impl<T, D, SM> Log for Matrix<SM, D>
where T: Num, D: DimTrait, SM: ToViewMutMemory<Item = T>,

source§

fn log(&mut self, source: Matrix<ViewMem<'_, T>, D>)

Computes the element-wise logarithm of source and stores the result in self. Read more
source§

fn log_assign(&mut self)

Computes the element-wise logarithm of self in-place.
source§

impl<T, D1, D3, M1, M3> MatrixAcos<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn acos(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixAcosh<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn acosh(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D2, D3, M1, M2, M3> MatrixAdd<Matrix<M1, D1>, Matrix<M2, D2>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D2: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn add(&mut self, lhs: Matrix<M1, D1>, rhs: Matrix<M2, D2>)

source§

impl<T, D1, D2, M1, M2> MatrixAdd<Matrix<M1, D1>, T> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn add(&mut self, lhs: Matrix<M1, D1>, rhs: T)

source§

impl<T, D1, D2, M1, M2> MatrixAdd<T, Matrix<M1, D1>> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn add(&mut self, lhs: T, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>> MatrixAddAssign<Matrix<M1, D1>> for Matrix<M2, D2>

source§

fn add_assign(&mut self, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D: DimTrait, M: ToViewMutMemory<Item = T>> MatrixAddAssign<T> for Matrix<M, D>

source§

fn add_assign(&mut self, rhs: T)

source§

impl<M: Memory> MatrixAddAxis for Matrix<M, DimDyn>

source§

fn add_axis(&mut self, axis: usize)

source§

impl<T, D1, D3, M1, M3> MatrixAsin<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn asin(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixAsinh<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn asinh(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixAtan<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn atan(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixAtanh<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn atanh(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T: Num, M: Memory<Item = T>, S: DimTrait> MatrixBase for Matrix<M, S>

§

type Dim = S

§

type Item = T

source§

fn shape_stride(&self) -> ShapeStride<Self::Dim>

source§

fn is_default_stride(&self) -> bool

source§

fn shape(&self) -> Self::Dim

source§

fn stride(&self) -> Self::Dim

source§

fn is_transposed_default_stride(&self) -> bool

source§

impl<T, D1, D3, M1, M3> MatrixCos<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn cos(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixCosh<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn cosh(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D2, D3, M1, M2, M3> MatrixDiv<Matrix<M1, D1>, Matrix<M2, D2>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D2: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn div(&mut self, lhs: Matrix<M1, D1>, rhs: Matrix<M2, D2>)

source§

impl<T, D1, D2, M1, M2> MatrixDiv<Matrix<M1, D1>, T> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn div(&mut self, lhs: Matrix<M1, D1>, rhs: T)

source§

impl<T, D1, D2, M1, M2> MatrixDiv<T, Matrix<M1, D1>> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn div(&mut self, lhs: T, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>> MatrixDivAssign<Matrix<M1, D1>> for Matrix<M2, D2>

source§

fn div_assign(&mut self, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D: DimTrait, M: ToViewMutMemory<Item = T>> MatrixDivAssign<T> for Matrix<M, D>

source§

fn div_assign(&mut self, rhs: T)

source§

impl<T: Num, M: ToViewMutMemory<Item = T> + ToViewMemory> MatrixIter<T> for Matrix<M, DimDyn>

source§

fn map_axis<F>(&self, axis: usize, fn_map: F) -> Matrix<OwnedMem<T>, DimDyn>
where F: FnMut(Matrix<ViewMutMem<'_, T>, DimDyn>),

source§

fn map_axis_mut<F>(&mut self, axis: usize, fn_map: F)
where F: FnMut(Matrix<ViewMutMem<'_, T>, DimDyn>),

source§

impl<T, D1, D2, D3, M1, M2, M3> MatrixMul<Matrix<M1, D1>, Matrix<M2, D2>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D2: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn mul(&mut self, lhs: Matrix<M1, D1>, rhs: Matrix<M2, D2>)

source§

impl<T, D1, D2, M1, M2> MatrixMul<Matrix<M1, D1>, T> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn mul(&mut self, lhs: Matrix<M1, D1>, rhs: T)

source§

impl<T, D1, D2, M1, M2> MatrixMul<T, Matrix<M1, D1>> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn mul(&mut self, lhs: T, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>> MatrixMulAssign<Matrix<M1, D1>> for Matrix<M2, D2>

source§

fn mul_assign(&mut self, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D: DimTrait, M: ToViewMutMemory<Item = T>> MatrixMulAssign<T> for Matrix<M, D>

source§

fn mul_assign(&mut self, rhs: T)

source§

impl<T, D1, D3, M1, M3> MatrixSin<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn sin(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixSinh<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn sinh(&mut self, lhs: Matrix<M1, D1>)

source§

impl<M: ToViewMemory, D: DimTrait, S: SliceTrait<Dim = D>> MatrixSlice<S> for Matrix<M, D>

§

type Output<'a> = Matrix<ViewMem<'a, <M as Memory>::Item>, D> where Self: 'a

source§

fn slice(&self, index: S) -> Self::Output<'_>

source§

impl<T, M, D> MatrixSliceDyn for Matrix<M, D>
where T: Num, M: Memory<Item = T> + ToViewMemory, D: DimTrait,

§

type Output<'a> = Matrix<ViewMem<'a, <Matrix<M, D> as MatrixBase>::Item>, DimDyn> where Self: 'a

source§

fn slice_dyn(&self, index: Slice) -> Self::Output<'_>

source§

impl<M: ToViewMutMemory, D: DimTrait, S: SliceTrait<Dim = D>> MatrixSliceMut<S> for Matrix<M, D>

§

type Output<'a> = Matrix<ViewMutMem<'a, <M as Memory>::Item>, D> where Self: 'a

source§

fn slice_mut(&mut self, index: S) -> Self::Output<'_>

source§

impl<T, M, D> MatrixSliceMutDyn for Matrix<M, D>
where T: Num, M: Memory<Item = T> + ToViewMutMemory, D: DimTrait,

§

type Output<'a> = Matrix<ViewMutMem<'a, <Matrix<M, D> as MatrixBase>::Item>, DimDyn> where Self: 'a

source§

fn slice_mut_dyn(&mut self, index: Slice) -> Self::Output<'_>

source§

impl<T, D1, D2, D3, M1, M2, M3> MatrixSub<Matrix<M1, D1>, Matrix<M2, D2>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D2: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn sub(&mut self, lhs: Matrix<M1, D1>, rhs: Matrix<M2, D2>)

source§

impl<T, D1, D2, M1, M2> MatrixSub<Matrix<M1, D1>, T> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn sub(&mut self, lhs: Matrix<M1, D1>, rhs: T)

source§

impl<T, D1, D2, M1, M2> MatrixSub<T, Matrix<M1, D1>> for Matrix<M2, D2>
where T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>,

source§

fn sub(&mut self, lhs: T, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D1: DimTrait, D2: DimTrait, M1: ToViewMemory<Item = T>, M2: ToViewMutMemory<Item = T>> MatrixSubAssign<Matrix<M1, D1>> for Matrix<M2, D2>

source§

fn sub_assign(&mut self, rhs: Matrix<M1, D1>)

source§

impl<T: Num, D: DimTrait, M: ToViewMutMemory<Item = T>> MatrixSubAssign<T> for Matrix<M, D>

source§

fn sub_assign(&mut self, rhs: T)

source§

impl<'a, T: Num> MatrixSum for Matrix<ViewMem<'a, T>, DimDyn>

§

type Output = Matrix<OwnedMem<T>, DimDyn>

source§

fn sum(self, axis: usize, keep_dim: bool) -> Self::Output

source§

impl<T, D1, D3, M1, M3> MatrixTan<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn tan(&mut self, lhs: Matrix<M1, D1>)

source§

impl<T, D1, D3, M1, M3> MatrixTanh<Matrix<M1, D1>> for Matrix<M3, D3>
where T: Num, D1: DimTrait, D3: DimTrait, M1: ToViewMemory<Item = T>, M3: ToViewMutMemory<Item = T>,

source§

fn tanh(&mut self, lhs: Matrix<M1, D1>)

source§

impl<'a, T, D> MaxIdx<T, D> for Matrix<ViewMem<'a, T>, D>
where T: Num, D: DimTrait,

source§

fn max_idx(self) -> DimDyn

source§

fn max(self) -> T

source§

impl<T: Num, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, D1: DimTrait, D2: DimTrait> Mul<Matrix<M1, D1>> for Matrix<M2, D2>

§

type Output = Matrix<OwnedMem<T>, D2>

The resulting type after applying the * operator.
source§

fn mul(self, rhs: Matrix<M1, D1>) -> Self::Output

Performs the * operation. Read more
source§

impl<T: Num, M: ToViewMemory<Item = T> + ToOwnedMemory, D: DimTrait> Mul<T> for Matrix<M, D>

§

type Output = Matrix<<M as ToOwnedMemory>::Owned, D>

The resulting type after applying the * operator.
source§

fn mul(self, rhs: T) -> Self::Output

Performs the * operation. Read more
source§

impl<M: Owned, S: DimTrait> OwnedMatrix for Matrix<M, S>

source§

fn from_vec<I: Into<Self::Dim>>(vec: Vec<Self::Item>, dim: I) -> Self

source§

impl<'a, T: Num> Relu<T> for Matrix<ViewMutMem<'a, T>, DimDyn>

source§

fn relu(&mut self, source: Matrix<ViewMem<'_, T>, DimDyn>)

source§

fn relu_backward_mask(&mut self, source: Matrix<ViewMem<'_, T>, DimDyn>)

source§

impl<T: Num, D: DimTrait, V: ToViewMemory<Item = T>> Reshape<T> for Matrix<V, D>

source§

fn reshape<I: Into<DimDyn>>( &self, new_shape: I ) -> Matrix<ViewMem<'_, T>, DimDyn>

source§

fn reshape_new_matrix<I: Into<DimDyn>>( &self, new_shape: I ) -> Matrix<OwnedMem<T>, DimDyn>

source§

impl<T: Num, D: DimTrait, V: ToViewMutMemory<Item = T>> ReshapeMut<T> for Matrix<V, D>

source§

fn reshape_mut<I: Into<DimDyn>>( &mut self, new_shape: I ) -> Matrix<ViewMutMem<'_, T>, DimDyn>

source§

impl<T: Num, D: DimTrait> ReshapeNoAlloc<T> for Matrix<OwnedMem<T>, D>

source§

fn reshape_no_alloc_owned<I: Into<DimDyn>>( self, new_shape: I ) -> Matrix<OwnedMem<T>, DimDyn>

source§

impl<M, S> Serialize for Matrix<M, S>
where M: Serialize, S: Serialize,

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl<T: Num, M: ToViewMutMemory<Item = T>> SoftMax<T> for Matrix<M, DimDyn>

source§

fn softmax_assign( &mut self, source: Matrix<ViewMem<'_, T>, DimDyn>, axis: usize )

source§

impl<T: Num, M1: ToViewMemory<Item = T>, M2: ToViewMemory<Item = T>, D1: DimTrait, D2: DimTrait> Sub<Matrix<M1, D1>> for Matrix<M2, D2>

§

type Output = Matrix<OwnedMem<T>, D2>

The resulting type after applying the - operator.
source§

fn sub(self, rhs: Matrix<M1, D1>) -> Self::Output

Performs the - operation. Read more
source§

impl<T: Num, M: ToViewMemory<Item = T> + ToOwnedMemory, D: DimTrait> Sub<T> for Matrix<M, D>

§

type Output = Matrix<<M as ToOwnedMemory>::Owned, D>

The resulting type after applying the - operator.
source§

fn sub(self, rhs: T) -> Self::Output

Performs the - operation. Read more
source§

impl<T, M, D: DimTrait> ToDefaultStride<T> for Matrix<M, D>
where T: Num, M: ToViewMemory<Item = T>,

source§

impl<M: ToOwnedMemory, S: DimTrait> ToOwnedMatrix for Matrix<M, S>

§

type Owned = Matrix<<M as ToOwnedMemory>::Owned, S>

source§

fn to_owned_matrix(&self) -> Self::Owned

source§

impl<M: ToViewMemory, S: DimTrait> ToViewMatrix for Matrix<M, S>

source§

fn to_view(&self) -> Matrix<ViewMem<'_, M::Item>, S>

source§

impl<M: ToViewMutMemory, S: DimTrait> ToViewMutMatrix for Matrix<M, S>

source§

fn to_view_mut(&mut self) -> Matrix<ViewMutMem<'_, M::Item>, S>

source§

impl<T: Num, M: Memory<Item = T>> Transpose for Matrix<M, Dim2>

source§

fn transpose(&mut self)

source§

impl<T: Num, M: Memory<Item = T>> Transpose for Matrix<M, Dim3>

source§

fn transpose(&mut self)

source§

impl<T: Num, M: Memory<Item = T>> Transpose for Matrix<M, Dim4>

source§

fn transpose(&mut self)

source§

impl<T: Num, M: Memory<Item = T>> Transpose for Matrix<M, DimDyn>

source§

fn transpose(&mut self)

source§

impl<T: Num, M: ToViewMemory<Item = T>> TransposeInplace<T> for Matrix<M, DimDyn>

source§

impl<M: View, S: DimTrait> ViewMatrix for Matrix<M, S>

source§

impl<M: ViewMut, S: DimTrait> ViewMutMatix for Matrix<M, S>

Auto Trait Implementations§

§

impl<M, S> Freeze for Matrix<M, S>
where M: Freeze, S: Freeze,

§

impl<M, S> RefUnwindSafe for Matrix<M, S>

§

impl<M, S> Send for Matrix<M, S>
where M: Send, S: Send,

§

impl<M, S> Sync for Matrix<M, S>
where M: Sync, S: Sync,

§

impl<M, S> Unpin for Matrix<M, S>
where M: Unpin, S: Unpin,

§

impl<M, S> UnwindSafe for Matrix<M, S>
where M: UnwindSafe, S: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<D, T, OM> Ones for OM
where D: DimTrait, T: Num, OM: OwnedMatrix<Dim = D, Item = T> + MatrixBase,

source§

fn ones<I>(dim: I) -> OM
where I: Into<D>,

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToString for T
where T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T, D, OM> Zeros for OM
where T: Num, D: DimTrait, OM: OwnedMatrix<Dim = D, Item = T> + MatrixBase,

source§

fn zeros<I>(dim: I) -> OM
where I: Into<<OM as MatrixBase>::Dim>,

source§

fn zeros_like<M>(m: M) -> OM
where M: MatrixBase,

source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,