pub struct Matrix<T: RDSTyped> { /* private fields */ }
Trait Implementations§
Source§impl<T: RDSTyped> Tensor<T> for Matrix<T>
impl<T: RDSTyped> Tensor<T> for Matrix<T>
fn from_scalar<R: AsRef<[usize]>>(shape: R, s: T) -> Self
fn from_tensor<W: Tensor<S>, S: RDSTyped + CastTo<T>>(tensor: &W) -> Self
fn from_slice<R: AsRef<[usize]>, S: AsRef<[T]>>(shape: R, slice: S) -> Self
fn from_boxed_slice<R: AsRef<[usize]>>(shape: R, data: Box<[T]>) -> Self
fn into_boxed_slice(self) -> Box<[T]>
fn dim(&self) -> usize
fn shape(&self) -> &[usize]
fn strides(&self) -> &[usize]
fn size(&self) -> usize
fn rds_type(&self) -> RDSType
fn get_raw_array(&self) -> &[T]
fn get_raw_array_mut(&mut self) -> &mut [T]
fn insert<W: Tensor<T>>(&mut self, dim: usize, pos: usize, tensor: &W)
fn extract<R: AsRef<[Range<usize>]>>(&self, bounds: R) -> Self
fn remove<R: AsRef<[Range<usize>]>>(&mut self, bounds: R)
fn assign<R: AsRef<[Range<usize>]>, W: Tensor<T>>( &mut self, bounds: R, tensor: &W, )
fn transpose(&mut self)
fn zeros<R: AsRef<[usize]>>(shape: R) -> Self
fn ones<R: AsRef<[usize]>>(shape: R) -> Self
fn effective_dim(&self) -> usize
fn reshape_into_vector<R: AsRef<[usize]>>(self, shape: R) -> Vector<T>
fn reshape_into_matrix<R: AsRef<[usize]>>(self, shape: R) -> Matrix<T>
fn reshape_into_tensor<R: AsRef<[usize]>>(self, shape: R) -> TensorN<T>
fn right_split(&mut self, dim: usize, pos: usize) -> Self
fn left_split(&mut self, dim: usize, pos: usize) -> Self
Auto Trait Implementations§
impl<T> Freeze for Matrix<T>
impl<T> RefUnwindSafe for Matrix<T>where
T: RefUnwindSafe,
impl<T> Send for Matrix<T>where
T: Send,
impl<T> Sync for Matrix<T>where
T: Sync,
impl<T> Unpin for Matrix<T>where
T: Unpin,
impl<T> UnwindSafe for Matrix<T>where
T: UnwindSafe,
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