Struct TensorBase

Source
pub struct TensorBase<S, D>
where D: DimAPI,
{ /* private fields */ }

Implementations§

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI + DimSmallerOneAPI, D::SmallerOne: DimAPI, B: DeviceAPI<T> + DeviceIndexSelectAPI<T, D> + DeviceCreationAnyAPI<T>,

Source

pub fn index_select_f<I>( &self, axis: isize, indices: I, ) -> Result<Tensor<T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn index_select<I>(&self, axis: isize, indices: I) -> Tensor<T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Returns a new tensor, which indexes the input tensor along dimension axis using the entries in indices.

§See also

This function should be similar to PyTorch’s torch.index_select.

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI + DimSmallerOneAPI, D::SmallerOne: DimAPI, B: DeviceAPI<T> + DeviceIndexSelectAPI<T, D> + DeviceCreationAnyAPI<T>,

Source

pub fn bool_select_f<I>( &self, axis: isize, indices: I, ) -> Result<Tensor<T, B, D>>
where I: TryInto<AxesIndex<bool>, Error = Error>,

Source

pub fn bool_select<I>(&self, axis: isize, indices: I) -> Tensor<T, B, D>
where I: TryInto<AxesIndex<bool>, Error = Error>,

Returns a new tensor, which indexes the input tensor along dimension axis using the boolean entries in mask.

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn assign_f<TRB>(&mut self, b: TRB) -> Result<()>
where Self: TensorAssignAPI<TRB>,

Source

pub fn assign<TRB>(&mut self, b: TRB)
where Self: TensorAssignAPI<TRB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn fill_f<T>(&mut self, b: T) -> Result<()>
where Self: TensorFillAPI<T>,

Source

pub fn fill<T>(&mut self, b: T)
where Self: TensorFillAPI<T>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, T: Clone, D: DimAPI, B: DeviceAPI<T> + DeviceCreationAnyAPI<T>,

Source

pub fn full_like(&self, fill: T) -> Tensor<T, B, D>

Source

pub fn full_like_f(&self, fill: T) -> Result<Tensor<T, B, D>>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, T: Num, B: DeviceAPI<T> + DeviceCreationNumAPI<T>,

Source

pub fn ones_like(&self) -> Tensor<T, B, D>

New tensor filled with ones and having the same shape as an input tensor.

§See also

ones_like

Source

pub fn ones_like_f(&self) -> Result<Tensor<T, B, D>>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, T: Num, B: DeviceAPI<T> + DeviceCreationNumAPI<T>,

Source

pub fn zeros_like(&self) -> Tensor<T, B, D>

New tensor filled with zeros and having the same shape as an input tensor.

§See also

zeros_like

Source

pub fn zeros_like_f(&self) -> Result<Tensor<T, B, D>>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn into_slice_f<I>(self, index: I) -> Result<TensorAny<R, T, B, IxD>>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn into_slice<I>(self, index: I) -> TensorAny<R, T, B, IxD>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn slice_f<I>(&self, index: I) -> Result<TensorView<'_, T, B, IxD>>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn slice<I>(&self, index: I) -> TensorView<'_, T, B, IxD>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn i_f<I>(&self, index: I) -> Result<TensorView<'_, T, B, IxD>>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn i<I>(&self, index: I) -> TensorView<'_, T, B, IxD>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataMutAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn slice_mut_f<I>(&mut self, index: I) -> Result<TensorMut<'_, T, B, IxD>>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn slice_mut<I>(&mut self, index: I) -> TensorMut<'_, T, B, IxD>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn i_mut_f<I>(&mut self, index: I) -> Result<TensorMut<'_, T, B, IxD>>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source

pub fn i_mut<I>(&mut self, index: I) -> TensorMut<'_, T, B, IxD>
where I: TryInto<AxesIndex<Indexer>, Error = Error>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI + DimSmallerOneAPI, D::SmallerOne: DimAPI,

Source

pub fn into_diagonal_f( self, diagonal_args: impl Into<DiagonalArgs>, ) -> Result<TensorAny<R, T, B, D::SmallerOne>>

Source

pub fn into_diagonal( self, diagonal_args: impl Into<DiagonalArgs>, ) -> TensorAny<R, T, B, D::SmallerOne>

Source

pub fn diagonal_f( &self, diagonal_args: impl Into<DiagonalArgs>, ) -> Result<TensorView<'_, T, B, D::SmallerOne>>

Source

pub fn diagonal( &self, diagonal_args: impl Into<DiagonalArgs>, ) -> TensorView<'_, T, B, D::SmallerOne>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataMutAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI + DimSmallerOneAPI, D::SmallerOne: DimAPI,

Source

pub fn into_diagonal_mut_f( self, diagonal_args: impl Into<DiagonalArgs>, ) -> Result<TensorAny<R, T, B, D::SmallerOne>>

Source

pub fn into_diagonal_mut( self, diagonal_args: impl Into<DiagonalArgs>, ) -> TensorAny<R, T, B, D::SmallerOne>

Source

pub fn diagonal_mut_f( &mut self, diagonal_args: impl Into<DiagonalArgs>, ) -> Result<TensorMut<'_, T, B, D::SmallerOne>>

Source

pub fn diagonal_mut( &mut self, diagonal_args: impl Into<DiagonalArgs>, ) -> TensorMut<'_, T, B, D::SmallerOne>

Source§

impl<T, B, D> TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub unsafe fn index_uncheck<I>(&self, index: I) -> &T
where I: AsRef<[usize]>,

§Safety

This function is unsafe because it does not check the validity of the index.

Source§

impl<T, B, D> TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub unsafe fn index_uncheck<I>(&self, index: I) -> &T
where I: AsRef<[usize]>,

§Safety

This function is unsafe because it does not check the validity of the index.

Source§

impl<T, B, D> TensorBase<Storage<DataMut<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub unsafe fn index_uncheck<I>(&self, index: I) -> &T
where I: AsRef<[usize]>,

§Safety

This function is unsafe because it does not check the validity of the index.

Source§

impl<T, B, D> TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub unsafe fn index_uncheck<I>(&self, index: I) -> &T
where I: AsRef<[usize]>,

§Safety

This function is unsafe because it does not check the validity of the index.

Source§

impl<T, B, D> TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub unsafe fn index_mut_uncheck<I>(&mut self, index: I) -> &mut T
where I: AsRef<[usize]>,

§Safety

This function is unsafe because it does not check the validity of the index.

Source§

impl<T, B, D> TensorBase<Storage<DataMut<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub unsafe fn index_mut_uncheck<I>(&mut self, index: I) -> &mut T
where I: AsRef<[usize]>,

§Safety

This function is unsafe because it does not check the validity of the index.

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where T: Clone, R: DataCloneAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn axes_iter_with_order_f<I>( &self, axes: I, order: TensorIterOrder, ) -> Result<IterAxesView<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn axes_iter_f<I>(&self, axes: I) -> Result<IterAxesView<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn axes_iter_with_order<I>( &self, axes: I, order: TensorIterOrder, ) -> IterAxesView<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn axes_iter<I>(&self, axes: I) -> IterAxesView<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where T: Clone, R: DataMutAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn axes_iter_mut_with_order_f<I>( &'a mut self, axes: I, order: TensorIterOrder, ) -> Result<IterAxesMut<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn axes_iter_mut_f<I>( &'a mut self, axes: I, ) -> Result<IterAxesMut<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn axes_iter_mut_with_order<I>( &'a mut self, axes: I, order: TensorIterOrder, ) -> IterAxesMut<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn axes_iter_mut<I>(&'a mut self, axes: I) -> IterAxesMut<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where T: Clone, R: DataCloneAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn indexed_axes_iter_with_order_f<I>( &self, axes: I, order: TensorIterOrder, ) -> Result<IndexedIterAxesView<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn indexed_axes_iter_f<I>( &self, axes: I, ) -> Result<IndexedIterAxesView<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn indexed_axes_iter_with_order<I>( &self, axes: I, order: TensorIterOrder, ) -> IndexedIterAxesView<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn indexed_axes_iter<I>(&self, axes: I) -> IndexedIterAxesView<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where T: Clone, R: DataMutAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn indexed_axes_iter_mut_with_order_f<I>( &'a mut self, axes: I, order: TensorIterOrder, ) -> Result<IndexedIterAxesMut<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn indexed_axes_iter_mut_f<I>( &'a mut self, axes: I, ) -> Result<IndexedIterAxesMut<'a, T, B>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn indexed_axes_iter_mut_with_order<I>( &'a mut self, axes: I, order: TensorIterOrder, ) -> IndexedIterAxesMut<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn indexed_axes_iter_mut<I>( &'a mut self, axes: I, ) -> IndexedIterAxesMut<'a, T, B>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn iter_with_order_f( &self, order: TensorIterOrder, ) -> Result<IterVecView<'a, T, D>>

Source

pub fn iter_with_order(&self, order: TensorIterOrder) -> IterVecView<'a, T, D>

Source

pub fn iter_f(&self) -> Result<IterVecView<'a, T, D>>

Source

pub fn iter(&self) -> IterVecView<'a, T, D>

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataMutAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn iter_mut_with_order_f( &'a mut self, order: TensorIterOrder, ) -> Result<IterVecMut<'a, T, D>>

Source

pub fn iter_mut_with_order( &'a mut self, order: TensorIterOrder, ) -> IterVecMut<'a, T, D>

Source

pub fn iter_mut_f(&'a mut self) -> Result<IterVecMut<'a, T, D>>

Source

pub fn iter_mut(&'a mut self) -> IterVecMut<'a, T, D>

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataMutAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + 'a,

Source

pub fn indexed_iter_mut_with_order_f( &'a mut self, order: TensorIterOrder, ) -> Result<IndexedIterVecMut<'a, T, D>>

Source

pub fn indexed_iter_mut_with_order( &'a mut self, order: TensorIterOrder, ) -> IndexedIterVecMut<'a, T, D>

Source

pub fn indexed_iter_mut_f(&'a mut self) -> Result<IndexedIterVecMut<'a, T, D>>

Source

pub fn indexed_iter_mut(&'a mut self) -> IndexedIterVecMut<'a, T, D>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn to_broadcast<D2>(&self, shape: D2) -> TensorView<'_, T, B, D2>
where D2: DimAPI, D: DimMaxAPI<D2, Max = D2>,

Broadcasts an array to a specified shape.

§See also

to_broadcast

Source

pub fn to_broadcast_f<D2>(&self, shape: D2) -> Result<TensorView<'_, T, B, D2>>
where D2: DimAPI, D: DimMaxAPI<D2, Max = D2>,

Source

pub fn into_broadcast<D2>(self, shape: D2) -> TensorAny<R, T, B, D2>
where D2: DimAPI, D: DimMaxAPI<D2, Max = D2>,

Broadcasts an array to a specified shape.

§See also

to_broadcast

Source

pub fn into_broadcast_f<D2>(self, shape: D2) -> Result<TensorAny<R, T, B, D2>>
where D2: DimAPI, D: DimMaxAPI<D2, Max = D2>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn expand_dims<I>(&self, axes: I) -> TensorView<'_, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Expands the shape of an array by inserting a new axis (dimension) of size one at the position specified by axis.

§See also

expand_dims

Source

pub fn expand_dims_f<I>(&self, axes: I) -> Result<TensorView<'_, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn into_expand_dims<I>(self, axes: I) -> TensorAny<R, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Expands the shape of an array by inserting a new axis (dimension) of size one at the position specified by axis.

§See also

expand_dims

Source

pub fn into_expand_dims_f<I>(self, axes: I) -> Result<TensorAny<R, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn flip<I>(&self, axis: I) -> TensorView<'_, T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Reverses the order of elements in an array along the given axis.

§See also

flip

Source

pub fn flip_f<I>(&self, axis: I) -> Result<TensorView<'_, T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn into_flip<I>(self, axis: I) -> TensorAny<R, T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Reverses the order of elements in an array along the given axis.

§See also

flip

Source

pub fn into_flip_f<I>(self, axis: I) -> Result<TensorAny<R, T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn transpose<I>(&self, axes: I) -> TensorView<'_, T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Permutes the axes (dimensions) of an array x.

§See also

transpose

Source

pub fn transpose_f<I>(&self, axes: I) -> Result<TensorView<'_, T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn into_transpose<I>(self, axes: I) -> TensorAny<R, T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Permutes the axes (dimensions) of an array x.

§See also

transpose

Source

pub fn into_transpose_f<I>(self, axes: I) -> Result<TensorAny<R, T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn permute_dims<I>(&self, axes: I) -> TensorView<'_, T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Permutes the axes (dimensions) of an array x.

§See also

transpose

Source

pub fn permute_dims_f<I>(&self, axes: I) -> Result<TensorView<'_, T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn into_permute_dims<I>(self, axes: I) -> TensorAny<R, T, B, D>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Permutes the axes (dimensions) of an array x.

§See also

transpose

Source

pub fn into_permute_dims_f<I>(self, axes: I) -> Result<TensorAny<R, T, B, D>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn reverse_axes(&self) -> TensorView<'_, T, B, D>

Reverse the order of elements in an array along the given axis.

§See also

reverse_axes

Source

pub fn into_reverse_axes(self) -> TensorAny<R, T, B, D>

Reverse the order of elements in an array along the given axis.

§See also

reverse_axes

Source

pub fn t(&self) -> TensorView<'_, T, B, D>

Reverse the order of elements in an array along the given axis.

§See also

reverse_axes

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn swapaxes<I>(&self, axis1: I, axis2: I) -> TensorView<'_, T, B, D>
where I: TryInto<isize>,

Interchange two axes of an array.

§See also

swapaxes

Source

pub fn swapaxes_f<I>( &self, axis1: I, axis2: I, ) -> Result<TensorView<'_, T, B, D>>
where I: TryInto<isize>,

Source

pub fn into_swapaxes<I>(self, axis1: I, axis2: I) -> TensorAny<R, T, B, D>
where I: TryInto<isize>,

Interchange two axes of an array.

§See also

swapaxes

Source

pub fn into_swapaxes_f<I>( self, axis1: I, axis2: I, ) -> Result<TensorAny<R, T, B, D>>
where I: TryInto<isize>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn squeeze<I>(&self, axis: I) -> TensorView<'_, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Removes singleton dimensions (axes) from x.

§See also

squeeze

Source

pub fn squeeze_f<I>(&self, axis: I) -> Result<TensorView<'_, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn into_squeeze<I>(self, axis: I) -> TensorAny<R, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Removes singleton dimensions (axes) from x.

§See also

squeeze

Source

pub fn into_squeeze_f<I>(self, axis: I) -> Result<TensorAny<R, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where D: DimAPI, R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>,

Source

pub fn to_dim<D2>(&self) -> TensorView<'_, T, B, D2>
where D2: DimAPI, D: DimIntoAPI<D2>,

Convert layout to the other dimension.

This is mostly used when converting static dimension to dynamic dimension or vice versa.

§See also

into_dim

Source

pub fn to_dim_f<D2>(&self) -> Result<TensorView<'_, T, B, D2>>
where D2: DimAPI, D: DimIntoAPI<D2>,

Source

pub fn into_dim<D2>(self) -> TensorAny<R, T, B, D2>
where D2: DimAPI, D: DimIntoAPI<D2>,

Convert layout to another dimension.

§See also

into_dim

Source

pub fn into_dim_f<D2>(self) -> Result<TensorAny<R, T, B, D2>>
where D2: DimAPI, D: DimIntoAPI<D2>,

Source

pub fn to_dyn(&self) -> TensorView<'_, T, B, IxD>

Convert layout to dynamic dimension.

Source

pub fn into_dyn(self) -> TensorAny<R, T, B, IxD>

Convert layout to dynamic dimension.

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn reshape_assume_contig<D2>(&self, shape: D2) -> TensorView<'_, T, B, D2>
where D2: DimAPI,

Assuming contiguous array, reshapes an array without changing its data.

§See also

reshape_assume_contig

Source

pub fn reshape_assume_contig_f<D2>( &self, shape: D2, ) -> Result<TensorView<'_, T, B, D2>>
where D2: DimAPI,

Source

pub fn to_shape_assume_contig<D2>(&self, shape: D2) -> TensorView<'_, T, B, D2>
where D2: DimAPI,

Source

pub fn to_shape_assume_contig_f<D2>( &self, shape: D2, ) -> Result<TensorView<'_, T, B, D2>>
where D2: DimAPI,

Source

pub fn into_shape_assume_contig<D2>(self, shape: D2) -> TensorAny<R, T, B, D2>
where D2: DimAPI,

Source

pub fn into_shape_assume_contig_f<D2>( self, shape: D2, ) -> Result<TensorAny<R, T, B, D2>>
where D2: DimAPI,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw> + DataIntoCowAPI<'a>, D: DimAPI, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + OpAssignArbitaryAPI<T, IxD, D> + OpAssignAPI<T, IxD>, T: Clone,

Source

pub fn change_shape_f<I>(self, shape: I) -> Result<TensorCow<'a, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn change_shape<I>(self, shape: I) -> TensorCow<'a, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn into_shape_f<I>(self, shape: I) -> Result<Tensor<T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>, B::Raw: Clone + 'a,

Source

pub fn into_shape<I>(self, shape: I) -> Tensor<T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>, B::Raw: Clone + 'a,

Source

pub fn to_shape_f<I>(&'a self, shape: I) -> Result<TensorCow<'a, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn to_shape<I>(&'a self, shape: I) -> TensorCow<'a, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn reshape_f<I>(&'a self, shape: I) -> Result<TensorCow<'a, T, B, IxD>>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn reshape<I>(&'a self, shape: I) -> TensorCow<'a, T, B, IxD>
where I: TryInto<AxesIndex<isize>, Error = Error>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw> + DataIntoCowAPI<'a>, D: DimAPI, T: Clone, B: DeviceAPI<T> + DeviceCreationAnyAPI<T>,

Source

pub fn to_layout<D2>(&self, layout: Layout<D2>) -> TensorCow<'_, T, B, D2>
where D2: DimAPI, B: OpAssignArbitaryAPI<T, D2, D>,

Convert tensor to the other layout.

§See also

to_layout

Source

pub fn to_layout_f<D2>( &self, layout: Layout<D2>, ) -> Result<TensorCow<'_, T, B, D2>>
where D2: DimAPI, B: OpAssignArbitaryAPI<T, D2, D>,

Source

pub fn into_layout_f<D2>(self, layout: Layout<D2>) -> Result<Tensor<T, B, D2>>
where D2: DimAPI, B: OpAssignArbitaryAPI<T, D2, D> + OpAssignAPI<T, D2>, B::Raw: Clone + 'a,

Source

pub fn into_layout<D2>(self, layout: Layout<D2>) -> Tensor<T, B, D2>
where D2: DimAPI, B: OpAssignArbitaryAPI<T, D2, D> + OpAssignAPI<T, D2>, B::Raw: Clone + 'a,

Source

pub fn change_layout_f<D2>( self, layout: Layout<D2>, ) -> Result<TensorCow<'a, T, B, D2>>
where D2: DimAPI, B: OpAssignArbitaryAPI<T, D2, D>,

Source

pub fn change_layout<D2>(self, layout: Layout<D2>) -> TensorCow<'a, T, B, D2>
where D2: DimAPI, B: OpAssignArbitaryAPI<T, D2, D>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw> + DataIntoCowAPI<'a>, D: DimAPI, T: Clone, B: DeviceAPI<T> + DeviceCreationAnyAPI<T>,

Source

pub fn to_contig(&self, order: FlagOrder) -> TensorCow<'_, T, B, D>
where B: OpAssignArbitaryAPI<T, D, D>,

Convert tensor to contiguous, with specified layout.

Source

pub fn to_contig_f(&self, order: FlagOrder) -> Result<TensorCow<'_, T, B, D>>
where B: OpAssignArbitaryAPI<T, D, D>,

Source

pub fn into_contig_f(self, order: FlagOrder) -> Result<Tensor<T, B, D>>
where B: OpAssignArbitaryAPI<T, D, D> + OpAssignAPI<T, D>, B::Raw: Clone + 'a,

Source

pub fn into_contig(self, order: FlagOrder) -> Tensor<T, B, D>
where B: OpAssignArbitaryAPI<T, D, D> + OpAssignAPI<T, D>, B::Raw: Clone + 'a,

Source

pub fn change_contig_f(self, order: FlagOrder) -> Result<TensorCow<'a, T, B, D>>
where B: OpAssignArbitaryAPI<T, D, D>,

Source

pub fn change_contig(self, order: FlagOrder) -> TensorCow<'a, T, B, D>
where B: OpAssignArbitaryAPI<T, D, D>,

Source§

impl<'a, R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw> + DataIntoCowAPI<'a>, D: DimAPI, T: Clone, B: DeviceAPI<T> + DeviceCreationAnyAPI<T>,

Source

pub fn to_prefer(&self, order: FlagOrder) -> TensorCow<'_, T, B, D>
where B: OpAssignArbitaryAPI<T, D, D>,

Convert tensor to contiguous, with specified layout.

Source

pub fn to_prefer_f(&self, order: FlagOrder) -> Result<TensorCow<'_, T, B, D>>
where B: OpAssignArbitaryAPI<T, D, D>,

Source

pub fn into_prefer_f(self, order: FlagOrder) -> Result<Tensor<T, B, D>>
where B: OpAssignArbitaryAPI<T, D, D> + OpAssignAPI<T, D>, B::Raw: Clone + 'a,

Source

pub fn into_prefer(self, order: FlagOrder) -> Tensor<T, B, D>
where B: OpAssignArbitaryAPI<T, D, D> + OpAssignAPI<T, D>, B::Raw: Clone + 'a,

Source

pub fn change_prefer_f(self, order: FlagOrder) -> Result<TensorCow<'a, T, B, D>>
where B: OpAssignArbitaryAPI<T, D, D>,

Source

pub fn change_prefer(self, order: FlagOrder) -> TensorCow<'a, T, B, D>
where B: OpAssignArbitaryAPI<T, D, D>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T>,

Source

pub fn map_fnmut_f<'f, TOut>( &self, f: impl FnMut(&T) -> TOut + 'f, ) -> Result<Tensor<TOut, B, D>>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn FnMut(&mut TOut, &T) + 'f>,

Call f by reference on each element and create a new tensor with the new values.

Source

pub fn map_fnmut<'f, TOut>( &self, f: impl FnMut(&T) -> TOut + 'f, ) -> Tensor<TOut, B, D>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn FnMut(&mut TOut, &T) + 'f>,

Call f by reference on each element and create a new tensor with the new values.

Source

pub fn mapv_fnmut_f<'f, TOut>( &self, f: impl FnMut(T) -> TOut + 'f, ) -> Result<Tensor<TOut, B, D>>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn FnMut(&mut TOut, &T) + 'f>, T: Clone,

Call f by value on each element and create a new tensor with the new values.

Source

pub fn mapv_fnmut<'f, TOut>( &self, f: impl FnMut(T) -> TOut + 'f, ) -> Tensor<TOut, B, D>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn FnMut(&mut TOut, &T) + 'f>, T: Clone,

Call f by value on each element and create a new tensor with the new values.

Source

pub fn mapi_fnmut_f<'f>(&mut self, f: impl FnMut(&mut T) + 'f) -> Result<()>
where R: DataMutAPI<Data = B::Raw>, B: DeviceOp_MutA_API<T, D, dyn FnMut(&mut T) + 'f>,

Modify the tensor in place by calling f by mutable reference on each element.

Source

pub fn mapi_fnmut<'f>(&mut self, f: impl FnMut(&mut T) + 'f)
where R: DataMutAPI<Data = B::Raw>, B: DeviceOp_MutA_API<T, D, dyn FnMut(&mut T) + 'f>,

Modify the tensor in place by calling f by mutable reference on each element.

Source

pub fn mapvi_fnmut_f<'f>(&mut self, f: impl FnMut(T) -> T + 'f) -> Result<()>
where R: DataMutAPI<Data = B::Raw>, T: Clone, B: DeviceOp_MutA_API<T, D, dyn FnMut(&mut T) + 'f>,

Modify the tensor in place by calling f by value on each element.

Source

pub fn mapvi_fnmut<'f>(&mut self, f: impl FnMut(T) -> T + 'f)
where R: DataMutAPI<Data = B::Raw>, T: Clone, B: DeviceOp_MutA_API<T, D, dyn FnMut(&mut T) + 'f>,

Modify the tensor in place by calling f by value on each element.

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T>, T: Clone,

Source

pub fn mapb_fnmut_f<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl FnMut(&T, &T2) -> TOut + 'f, ) -> Result<Tensor<TOut, B, DOut>>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn FnMut(&mut TOut, &T, &T2) + 'f>,

Source

pub fn mapb_fnmut<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl FnMut(&T, &T2) -> TOut + 'f, ) -> Tensor<TOut, B, DOut>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn FnMut(&mut TOut, &T, &T2) + 'f>,

Source

pub fn mapvb_fnmut_f<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl FnMut(T, T2) -> TOut + 'f, ) -> Result<Tensor<TOut, B, DOut>>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, T: Clone, T2: Clone, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn FnMut(&mut TOut, &T, &T2) + 'f>,

Source

pub fn mapvb_fnmut<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl FnMut(T, T2) -> TOut + 'f, ) -> Tensor<TOut, B, DOut>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, T: Clone, T2: Clone, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn FnMut(&mut TOut, &T, &T2) + 'f>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T>,

Source

pub fn map_f<'f, TOut>( &self, f: impl Fn(&T) -> TOut + Send + Sync + 'f, ) -> Result<Tensor<TOut, B, D>>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn Fn(&mut TOut, &T) + Send + Sync + 'f>,

Call f by reference on each element and create a new tensor with the new values.

Source

pub fn map<'f, TOut>( &self, f: impl Fn(&T) -> TOut + Send + Sync + 'f, ) -> Tensor<TOut, B, D>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn Fn(&mut TOut, &T) + Send + Sync + 'f>,

Call f by reference on each element and create a new tensor with the new values.

Source

pub fn mapv_f<'f, TOut>( &self, f: impl Fn(T) -> TOut + Send + Sync + 'f, ) -> Result<Tensor<TOut, B, D>>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn Fn(&mut TOut, &T) + Send + Sync + 'f>, T: Clone,

Call f by value on each element and create a new tensor with the new values.

Source

pub fn mapv<'f, TOut>( &self, f: impl Fn(T) -> TOut + Send + Sync + 'f, ) -> Tensor<TOut, B, D>
where B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutA_RefB_API<TOut, T, D, dyn Fn(&mut TOut, &T) + Send + Sync + 'f>, T: Clone,

Call f by value on each element and create a new tensor with the new values.

Source

pub fn mapi_f<'f>( &mut self, f: impl Fn(&mut T) + Send + Sync + 'f, ) -> Result<()>
where R: DataMutAPI<Data = B::Raw>, B: DeviceOp_MutA_API<T, D, dyn Fn(&mut T) + Send + Sync + 'f>,

Modify the tensor in place by calling f by mutable reference on each element.

Source

pub fn mapi<'f>(&mut self, f: impl Fn(&mut T) + Send + Sync + 'f)
where R: DataMutAPI<Data = B::Raw>, B: DeviceOp_MutA_API<T, D, dyn Fn(&mut T) + Send + Sync + 'f>,

Modify the tensor in place by calling f by mutable reference on each element.

Source

pub fn mapvi_f<'f>( &mut self, f: impl Fn(T) -> T + Send + Sync + 'f, ) -> Result<()>
where R: DataMutAPI<Data = B::Raw>, T: Clone, B: DeviceOp_MutA_API<T, D, dyn Fn(&mut T) + Send + Sync + 'f>,

Modify the tensor in place by calling f by value on each element.

Source

pub fn mapvi<'f>(&mut self, f: impl Fn(T) -> T + Send + Sync + 'f)
where R: DataMutAPI<Data = B::Raw>, T: Clone, B: DeviceOp_MutA_API<T, D, dyn Fn(&mut T) + Send + Sync + 'f>,

Modify the tensor in place by calling f by value on each element.

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T>, T: Clone,

Source

pub fn mapb_f<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl Fn(&T, &T2) -> TOut + Send + Sync + 'f, ) -> Result<Tensor<TOut, B, DOut>>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn Fn(&mut TOut, &T, &T2) + Send + Sync + 'f>,

Source

pub fn mapb<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl Fn(&T, &T2) -> TOut + Send + Sync + 'f, ) -> Tensor<TOut, B, DOut>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn Fn(&mut TOut, &T, &T2) + Send + Sync + 'f>,

Source

pub fn mapvb_f<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl Fn(T, T2) -> TOut + Send + Sync + 'f, ) -> Result<Tensor<TOut, B, DOut>>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, T: Clone, T2: Clone, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn Fn(&mut TOut, &T, &T2) + Send + Sync + 'f>,

Source

pub fn mapvb<'f, R2, T2, D2, DOut, TOut>( &self, other: &TensorAny<R2, T2, B, D2>, f: impl Fn(T, T2) -> TOut + Send + Sync + 'f, ) -> Tensor<TOut, B, DOut>
where R2: DataAPI<Data = <B as DeviceRawAPI<T2>>::Raw>, D2: DimAPI, DOut: DimAPI, D: DimMaxAPI<D2, Max = DOut>, T: Clone, T2: Clone, B: DeviceAPI<TOut> + DeviceCreationAnyAPI<TOut> + DeviceOp_MutC_RefA_RefB_API<T, T2, TOut, DOut, dyn Fn(&mut TOut, &T, &T2) + Send + Sync + 'f>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub fn matmul_f<RB, TB, TC, DB, DC>( &self, rhs: &TensorAny<RB, TB, B, DB>, ) -> Result<Tensor<TC, B, DC>>
where RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DB: DimAPI, DC: DimAPI, T: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TB> + DeviceAPI<TC> + DeviceCreationAnyAPI<TC> + DeviceMatMulAPI<T, TB, TC, D, DB, DC>, LayoutMatMulConfig<D, DB>: LayoutMatMulAPI<D, DB, DC = DC>,

Source

pub fn matmul<RB, TB, TC, DB, DC>( &self, rhs: &TensorAny<RB, TB, B, DB>, ) -> Tensor<TC, B, DC>
where RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DB: DimAPI, DC: DimAPI, T: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TB> + DeviceAPI<TC> + DeviceCreationAnyAPI<TC> + DeviceMatMulAPI<T, TB, TC, D, DB, DC>, LayoutMatMulConfig<D, DB>: LayoutMatMulAPI<D, DB, DC = DC>,

Source

pub fn matmul_with_output_f<RB, RC, TB, TC, DB, DC>( &self, rhs: &TensorAny<RB, TB, B, DB>, c: &mut TensorAny<RC, TC, B, DC>, ) -> Result<()>
where RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, RC: DataMutAPI<Data = <B as DeviceRawAPI<TC>>::Raw>, DB: DimAPI, DC: DimAPI, T: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TB> + DeviceAPI<TC> + DeviceMatMulAPI<T, TB, TC, D, DB, DC>,

Source

pub fn matmul_with_output<RB, RC, TB, TC, DB, DC>( &self, rhs: &TensorAny<RB, TB, B, DB>, c: &mut TensorAny<RC, TC, B, DC>, )
where RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, RC: DataMutAPI<Data = <B as DeviceRawAPI<TC>>::Raw>, DB: DimAPI, DC: DimAPI, T: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TB> + DeviceAPI<TC> + DeviceMatMulAPI<T, TB, TC, D, DB, DC>,

Source

pub fn matmul_from_f<RA, RB, TA, TB, DA, DB>( &mut self, a: &TensorAny<RA, TA, B, DA>, b: &TensorAny<RB, TB, B, DB>, alpha: T, beta: T, ) -> Result<()>
where R: DataMutAPI<Data = <B as DeviceRawAPI<T>>::Raw>, RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI, DB: DimAPI, TA: Mul<TB, Output = T>, T: Mul<T, Output = T> + Add<T, Output = T> + Zero + One, B: DeviceAPI<TA> + DeviceAPI<TB> + DeviceMatMulAPI<TA, TB, T, DA, DB, D>,

Source

pub fn matmul_from<RA, RB, TA, TB, DA, DB>( &mut self, a: &TensorAny<RA, TA, B, DA>, b: &TensorAny<RB, TB, B, DB>, alpha: T, beta: T, )
where R: DataMutAPI<Data = <B as DeviceRawAPI<T>>::Raw>, RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI, DB: DimAPI, TA: Mul<TB, Output = T>, T: Mul<T, Output = T> + Add<T, Output = T> + Zero + One, B: DeviceAPI<TA> + DeviceAPI<TB> + DeviceMatMulAPI<TA, TB, T, DA, DB, D>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn add_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorAddAPI<TrB>>::Output>
where for<'a> &'a Self: TensorAddAPI<TrB>,

Source

pub fn add<TrB>(&self, b: TrB) -> <&Self as TensorAddAPI<TrB>>::Output
where for<'a> &'a Self: TensorAddAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn sub_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorSubAPI<TrB>>::Output>
where for<'a> &'a Self: TensorSubAPI<TrB>,

Source

pub fn sub<TrB>(&self, b: TrB) -> <&Self as TensorSubAPI<TrB>>::Output
where for<'a> &'a Self: TensorSubAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn mul_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorMulAPI<TrB>>::Output>
where for<'a> &'a Self: TensorMulAPI<TrB>,

Source

pub fn mul<TrB>(&self, b: TrB) -> <&Self as TensorMulAPI<TrB>>::Output
where for<'a> &'a Self: TensorMulAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn div_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorDivAPI<TrB>>::Output>
where for<'a> &'a Self: TensorDivAPI<TrB>,

Source

pub fn div<TrB>(&self, b: TrB) -> <&Self as TensorDivAPI<TrB>>::Output
where for<'a> &'a Self: TensorDivAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn rem_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorRemAPI<TrB>>::Output>
where for<'a> &'a Self: TensorRemAPI<TrB>,

Source

pub fn rem<TrB>(&self, b: TrB) -> <&Self as TensorRemAPI<TrB>>::Output
where for<'a> &'a Self: TensorRemAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn bitor_f<TrB>( &self, b: TrB, ) -> Result<<&Self as TensorBitOrAPI<TrB>>::Output>
where for<'a> &'a Self: TensorBitOrAPI<TrB>,

Source

pub fn bitor<TrB>(&self, b: TrB) -> <&Self as TensorBitOrAPI<TrB>>::Output
where for<'a> &'a Self: TensorBitOrAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn bitand_f<TrB>( &self, b: TrB, ) -> Result<<&Self as TensorBitAndAPI<TrB>>::Output>
where for<'a> &'a Self: TensorBitAndAPI<TrB>,

Source

pub fn bitand<TrB>(&self, b: TrB) -> <&Self as TensorBitAndAPI<TrB>>::Output
where for<'a> &'a Self: TensorBitAndAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn bitxor_f<TrB>( &self, b: TrB, ) -> Result<<&Self as TensorBitXorAPI<TrB>>::Output>
where for<'a> &'a Self: TensorBitXorAPI<TrB>,

Source

pub fn bitxor<TrB>(&self, b: TrB) -> <&Self as TensorBitXorAPI<TrB>>::Output
where for<'a> &'a Self: TensorBitXorAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn shl_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorShlAPI<TrB>>::Output>
where for<'a> &'a Self: TensorShlAPI<TrB>,

Source

pub fn shl<TrB>(&self, b: TrB) -> <&Self as TensorShlAPI<TrB>>::Output
where for<'a> &'a Self: TensorShlAPI<TrB>,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn shr_f<TrB>(&self, b: TrB) -> Result<<&Self as TensorShrAPI<TrB>>::Output>
where for<'a> &'a Self: TensorShrAPI<TrB>,

Source

pub fn shr<TrB>(&self, b: TrB) -> <&Self as TensorShrAPI<TrB>>::Output
where for<'a> &'a Self: TensorShrAPI<TrB>,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI + DimSmallerOneAPI, D::SmallerOne: DimAPI, B: DeviceAPI<T> + DeviceOpPackTriAPI<T> + DeviceCreationAnyAPI<T>,

Source

pub fn pack_tri_f(&self, uplo: FlagUpLo) -> Result<Tensor<T, B, D::SmallerOne>>

Source

pub fn pack_tri(&self, uplo: FlagUpLo) -> Tensor<T, B, D::SmallerOne>

Source

pub fn pack_tril_f(&self) -> Result<Tensor<T, B, D::SmallerOne>>

Source

pub fn pack_tril(&self) -> Tensor<T, B, D::SmallerOne>

Source

pub fn pack_triu_f(&self) -> Result<Tensor<T, B, D::SmallerOne>>

Source

pub fn pack_triu(&self) -> Tensor<T, B, D::SmallerOne>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI + DimLargerOneAPI, D::LargerOne: DimAPI, B: DeviceAPI<T> + DeviceOpUnpackTriAPI<T> + DeviceCreationAnyAPI<T>,

Source

pub fn unpack_tri( &self, uplo: FlagUpLo, symm: FlagSymm, ) -> Result<Tensor<T, B, D::LargerOne>>

Source

pub fn unpack_tril(&self, symm: FlagSymm) -> Tensor<T, B, D::LargerOne>

Source

pub fn unpack_triu(&self, symm: FlagSymm) -> Tensor<T, B, D::LargerOne>

Source

pub fn unpack_tri_f( &self, uplo: FlagUpLo, symm: FlagSymm, ) -> Result<Tensor<T, B, D::LargerOne>>

Source

pub fn unpack_tril_f( &self, symm: FlagSymm, ) -> Result<Tensor<T, B, D::LargerOne>>

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn neg_f(&self) -> Result<<&Self as TensorNegAPI>::Output>
where for<'a> &'a Self: TensorNegAPI,

Source

pub fn neg(&self) -> <&Self as TensorNegAPI>::Output
where for<'a> &'a Self: TensorNegAPI,

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Source

pub fn not_f(&self) -> Result<<&Self as TensorNotAPI>::Output>
where for<'a> &'a Self: TensorNotAPI,

Source

pub fn not(&self) -> <&Self as TensorNotAPI>::Output
where for<'a> &'a Self: TensorNotAPI,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where D: DimAPI, B: DeviceAPI<T>, R: DataAPI<Data = B::Raw>,

Methods for tensor ownership conversion.

Source

pub fn view(&self) -> TensorView<'_, T, B, D>

Get a view of tensor.

Source

pub fn view_mut(&mut self) -> TensorMut<'_, T, B, D>
where R: DataMutAPI,

Get a mutable view of tensor.

Source

pub fn into_cow<'a>(self) -> TensorCow<'a, T, B, D>
where R: DataIntoCowAPI<'a>,

Convert current tensor into copy-on-write.

Source

pub fn into_owned_keep_layout(self) -> Tensor<T, B, D>
where R::Data: Clone, R: DataCloneAPI,

Convert tensor into owned tensor.

Data is either moved or fully cloned. Layout is not involved; i.e. all underlying data is moved or cloned without changing layout.

§See also

Tensor::into_owned keep data in some conditions, otherwise clone. This function can avoid cases where data memory bulk is large, but tensor view is small.

Source

pub fn into_shared_keep_layout(self) -> TensorArc<T, B, D>
where R::Data: Clone, R: DataCloneAPI,

Convert tensor into shared tensor.

Data is either moved or cloned. Layout is not involved; i.e. all underlying data is moved or cloned without changing layout.

§See also

Tensor::into_shared keep data in some conditions, otherwise clone. This function can avoid cases where data memory bulk is large, but tensor view is small.

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataCloneAPI<Data = B::Raw>, R::Data: Clone, D: DimAPI, T: Clone, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + OpAssignAPI<T, D>,

Source

pub fn into_owned(self) -> Tensor<T, B, D>

Source

pub fn into_shared(self) -> TensorArc<T, B, D>

Source

pub fn to_owned(&self) -> Tensor<T, B, D>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw> + DataForceMutAPI<B::Raw>, B: DeviceAPI<T>, D: DimAPI,

Source

pub unsafe fn force_mut(&self) -> TensorMut<'_, T, B, D>

§Safety

This function is highly unsafe, as it entirely bypasses Rust’s lifetime and borrowing rules.

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + DeviceCreationAnyAPI<T> + OpAssignAPI<T, Ix1>,

Source

pub fn to_raw_f(&self) -> Result<Vec<T>>

Source

pub fn to_vec(&self) -> Vec<T>

Source§

impl<T, B, D> TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where T: Clone, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>> + DeviceCreationAnyAPI<T> + OpAssignAPI<T, Ix1>,

Source

pub fn into_vec_f(self) -> Result<Vec<T>>

Source

pub fn into_vec(self) -> Vec<T>

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataCloneAPI<Data = B::Raw>, B::Raw: Clone, T: Clone, D: DimAPI, B: DeviceAPI<T>,

Source

pub fn to_scalar_f(&self) -> Result<T>

Source

pub fn to_scalar(&self) -> T

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T, Raw = Vec<T>>,

Source

pub fn as_ptr(&self) -> *const T

Source

pub fn as_mut_ptr(&mut self) -> *mut T
where R: DataMutAPI,

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpSumAPI<T, D>,

Source

pub fn sum_all_f(&self) -> Result<B::TOut>

Source

pub fn sum_all(&self) -> B::TOut

Source

pub fn sum_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn sum_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn sum_f(&self) -> Result<B::TOut>

Source

pub fn sum(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpMinAPI<T, D>,

Source

pub fn min_all_f(&self) -> Result<B::TOut>

Source

pub fn min_all(&self) -> B::TOut

Source

pub fn min_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn min_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn min_f(&self) -> Result<B::TOut>

Source

pub fn min(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpMaxAPI<T, D>,

Source

pub fn max_all_f(&self) -> Result<B::TOut>

Source

pub fn max_all(&self) -> B::TOut

Source

pub fn max_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn max_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn max_f(&self) -> Result<B::TOut>

Source

pub fn max(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpProdAPI<T, D>,

Source

pub fn prod_all_f(&self) -> Result<B::TOut>

Source

pub fn prod_all(&self) -> B::TOut

Source

pub fn prod_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn prod_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn prod_f(&self) -> Result<B::TOut>

Source

pub fn prod(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpMeanAPI<T, D>,

Source

pub fn mean_all_f(&self) -> Result<B::TOut>

Source

pub fn mean_all(&self) -> B::TOut

Source

pub fn mean_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn mean_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn mean_f(&self) -> Result<B::TOut>

Source

pub fn mean(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpVarAPI<T, D>,

Source

pub fn var_all_f(&self) -> Result<B::TOut>

Source

pub fn var_all(&self) -> B::TOut

Source

pub fn var_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn var_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn var_f(&self) -> Result<B::TOut>

Source

pub fn var(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpStdAPI<T, D>,

Source

pub fn std_all_f(&self) -> Result<B::TOut>

Source

pub fn std_all(&self) -> B::TOut

Source

pub fn std_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn std_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn std_f(&self) -> Result<B::TOut>

Source

pub fn std(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpL2NormAPI<T, D>,

Source

pub fn l2_norm_all_f(&self) -> Result<B::TOut>

Source

pub fn l2_norm_all(&self) -> B::TOut

Source

pub fn l2_norm_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn l2_norm_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn l2_norm_f(&self) -> Result<B::TOut>

Source

pub fn l2_norm(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpArgMinAPI<T, D>,

Source

pub fn argmin_all_f(&self) -> Result<B::TOut>

Source

pub fn argmin_all(&self) -> B::TOut

Source

pub fn argmin_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn argmin_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn argmin_f(&self) -> Result<B::TOut>

Source

pub fn argmin(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpArgMaxAPI<T, D>,

Source

pub fn argmax_all_f(&self) -> Result<B::TOut>

Source

pub fn argmax_all(&self) -> B::TOut

Source

pub fn argmax_axes_f<I>(&self, axes: I) -> Result<Tensor<B::TOut, B, IxD>>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn argmax_axes<I>(&self, axes: I) -> Tensor<B::TOut, B, IxD>
where B: DeviceCreationAnyAPI<B::TOut>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn argmax_f(&self) -> Result<B::TOut>

Source

pub fn argmax(&self) -> B::TOut

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpUnraveledArgMinAPI<T, D>,

Source

pub fn unraveled_argmin_all_f(&self) -> Result<D>

Source

pub fn unraveled_argmin_all(&self) -> D

Source

pub fn unraveled_argmin_axes_f<I>(&self, axes: I) -> Result<Tensor<IxD, B, IxD>>
where B: DeviceAPI<IxD>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn unraveled_argmin_axes<I>(&self, axes: I) -> Tensor<IxD, B, IxD>
where B: DeviceAPI<IxD>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn unraveled_argmin_f(&self) -> Result<D>

Source

pub fn unraveled_argmin(&self) -> D

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = <B as DeviceRawAPI<T>>::Raw>, D: DimAPI, B: OpUnraveledArgMaxAPI<T, D>,

Source

pub fn unraveled_argmax_all_f(&self) -> Result<D>

Source

pub fn unraveled_argmax_all(&self) -> D

Source

pub fn unraveled_argmax_axes_f<I>(&self, axes: I) -> Result<Tensor<IxD, B, IxD>>
where B: DeviceAPI<IxD>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn unraveled_argmax_axes<I>(&self, axes: I) -> Tensor<IxD, B, IxD>
where B: DeviceAPI<IxD>, I: TryInto<AxesIndex<isize>, Error = Error>,

Source

pub fn unraveled_argmax_f(&self) -> Result<D>

Source

pub fn unraveled_argmax(&self) -> D

Source§

impl<S> TensorBase<S, Ix2>

Source

pub fn nrow(&self) -> usize

Source

pub fn ncol(&self) -> usize

Source

pub fn ld_row(&self) -> Option<usize>

Leading dimension in row-major order case.

This function will not return any value if the layout is not row-major.

Source

pub fn ld_col(&self) -> Option<usize>

Leading dimension in column-major order case.

This function will not return any value if the layout is not column-major.

Source

pub fn ld(&self, order: FlagOrder) -> Option<usize>

Leading dimension by order.

Source§

impl<S, D> TensorBase<S, D>
where D: DimAPI,

Basic definitions for tensor object.

Source

pub unsafe fn new_unchecked(storage: S, layout: Layout<D>) -> Self

Initialize tensor object.

§Safety

This function will not check whether data meets the standard of Storage<T, B>, or whether layout may exceed pointer bounds of data.

Source

pub fn storage(&self) -> &S

Source

pub fn storage_mut(&mut self) -> &mut S

Source

pub fn layout(&self) -> &Layout<D>

Source

pub fn shape(&self) -> &D

Source

pub fn stride(&self) -> &D::Stride

Source

pub fn offset(&self) -> usize

Source

pub fn ndim(&self) -> usize

Source

pub fn size(&self) -> usize

Source

pub fn into_data(self) -> S

Source

pub fn into_raw_parts(self) -> (S, Layout<D>)

Source

pub fn c_contig(&self) -> bool

Source

pub fn f_contig(&self) -> bool

Source

pub fn c_prefer(&self) -> bool

Source

pub fn f_prefer(&self) -> bool

Source§

impl<R, T, B, D> TensorBase<Storage<R, T, B>, D>
where R: DataAPI<Data = B::Raw>, D: DimAPI, B: DeviceAPI<T>,

Source

pub fn new_f(storage: Storage<R, T, B>, layout: Layout<D>) -> Result<Self>

Source

pub fn new(storage: Storage<R, T, B>, layout: Layout<D>) -> Self

Source

pub fn device(&self) -> &B

Source

pub fn data(&self) -> &R

Source

pub fn data_mut(&mut self) -> &mut R

Source

pub fn raw(&self) -> &B::Raw

Source

pub fn raw_mut(&mut self) -> &mut B::Raw
where R: DataMutAPI<Data = B::Raw>,

Source§

impl<T, B, D> TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where B: DeviceAPI<T>, D: DimAPI,

Source

pub fn is_owned(&self) -> bool

Source

pub fn is_ref(&self) -> bool

Source§

impl<T, B, D> TensorBase<Storage<DataReference<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>
where B: DeviceAPI<T>, D: DimAPI,

Source

pub fn is_ref(&self) -> bool

Source

pub fn is_mut(&self) -> bool

Trait Implementations§

Source§

impl<SA, DA, TrB> Add<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorAddAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorAddAPI<TrB>>::Output

The resulting type after applying the + operator.
Source§

fn add(self, b: TrB) -> Self::Output

Performs the + operation. Read more
Source§

impl<SA, DA, TrB> BitAnd<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorBitAndAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorBitAndAPI<TrB>>::Output

The resulting type after applying the & operator.
Source§

fn bitand(self, b: TrB) -> Self::Output

Performs the & operation. Read more
Source§

impl<SA, DA, TrB> BitOr<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorBitOrAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorBitOrAPI<TrB>>::Output

The resulting type after applying the | operator.
Source§

fn bitor(self, b: TrB) -> Self::Output

Performs the | operation. Read more
Source§

impl<SA, DA, TrB> BitXor<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorBitXorAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorBitXorAPI<TrB>>::Output

The resulting type after applying the ^ operator.
Source§

fn bitxor(self, b: TrB) -> Self::Output

Performs the ^ operation. Read more
Source§

impl<SA, DA, TrB> Div<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorDivAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorDivAPI<TrB>>::Output

The resulting type after applying the / operator.
Source§

fn div(self, b: TrB) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a, T, B, D> From<TensorBase<Storage<DataMut<'a, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>> for TensorReference<'a, T, B, D>
where B: DeviceAPI<T>, D: DimAPI,

Source§

fn from(tensor: TensorViewMut<'a, T, B, D>) -> Self

Converts to this type from the input type.
Source§

impl<'a, T, B, D> From<TensorBase<Storage<DataRef<'a, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>> for TensorReference<'a, T, B, D>
where B: DeviceAPI<T>, D: DimAPI,

Source§

fn from(tensor: TensorView<'a, T, B, D>) -> Self

Converts to this type from the input type.
Source§

impl<'a, T, B, D> From<TensorBase<Storage<DataReference<'a, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>> for TensorMut<'a, T, B, D>
where B: DeviceAPI<T>, D: DimAPI,

Source§

fn from(tensor: TensorReference<'a, T, B, D>) -> Self

Converts to this type from the input type.
Source§

impl<'a, T, B, D> From<TensorBase<Storage<DataReference<'a, <B as DeviceRawAPI<T>>::Raw>, T, B>, D>> for TensorView<'a, T, B, D>
where B: DeviceAPI<T>, D: DimAPI,

Source§

fn from(tensor: TensorReference<'a, T, B, D>) -> Self

Converts to this type from the input type.
Source§

impl<SA, DA, TrB> Mul<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorMulAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorMulAPI<TrB>>::Output

The resulting type after applying the * operator.
Source§

fn mul(self, b: TrB) -> Self::Output

Performs the * operation. Read more
Source§

impl<RA, RB, TA, TB, TC, DA, DB, DC, B> Rem<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI, DB: DimAPI, DC: DimAPI, TA: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<TC> + DeviceCreationAnyAPI<TC> + DeviceMatMulAPI<TA, TB, TC, DA, DB, DC>, LayoutMatMulConfig<DA, DB>: LayoutMatMulAPI<DA, DB, DC = DC>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<TC>>::Raw>, TC, B>, DC>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &TensorAny<RB, TB, B, DB>) -> Self::Output

Performs the % operation. Read more
Source§

impl<RA, RB, TA, TB, TC, DA, DB, DC, B> Rem<&TensorBase<Storage<RB, TB, B>, DB>> for TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI, DB: DimAPI, DC: DimAPI, TA: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<TC> + DeviceCreationAnyAPI<TC> + DeviceMatMulAPI<TA, TB, TC, DA, DB, DC>, LayoutMatMulConfig<DA, DB>: LayoutMatMulAPI<DA, DB, DC = DC>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<TC>>::Raw>, TC, B>, DC>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &TensorAny<RB, TB, B, DB>) -> Self::Output

Performs the % operation. Read more
Source§

impl<RA, RB, TA, TB, TC, DA, DB, DC, B> Rem<TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI, DB: DimAPI, DC: DimAPI, TA: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<TC> + DeviceCreationAnyAPI<TC> + DeviceMatMulAPI<TA, TB, TC, DA, DB, DC>, LayoutMatMulConfig<DA, DB>: LayoutMatMulAPI<DA, DB, DC = DC>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<TC>>::Raw>, TC, B>, DC>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: TensorAny<RB, TB, B, DB>) -> Self::Output

Performs the % operation. Read more
Source§

impl<RA, RB, TA, TB, TC, DA, DB, DC, B> Rem<TensorBase<Storage<RB, TB, B>, DB>> for TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI, DB: DimAPI, DC: DimAPI, TA: Mul<TB, Output = TC>, TC: Mul<TC, Output = TC> + Add<TC, Output = TC> + Zero + One, B: DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<TC> + DeviceCreationAnyAPI<TC> + DeviceMatMulAPI<TA, TB, TC, DA, DB, DC>, LayoutMatMulConfig<DA, DB>: LayoutMatMulAPI<DA, DB, DC = DC>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<TC>>::Raw>, TC, B>, DC>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: TensorAny<RB, TB, B, DB>) -> Self::Output

Performs the % operation. Read more
Source§

impl<SA, DA, TrB> Shl<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorShlAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorShlAPI<TrB>>::Output

The resulting type after applying the << operator.
Source§

fn shl(self, b: TrB) -> Self::Output

Performs the << operation. Read more
Source§

impl<SA, DA, TrB> Shr<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorShrAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorShrAPI<TrB>>::Output

The resulting type after applying the >> operator.
Source§

fn shr(self, b: TrB) -> Self::Output

Performs the >> operation. Read more
Source§

impl<SA, DA, TrB> Sub<TrB> for &TensorBase<SA, DA>
where DA: DimAPI, Self: TensorSubAPI<TrB>,

Source§

type Output = <&TensorBase<SA, DA> as TensorSubAPI<TrB>>::Output

The resulting type after applying the - operator.
Source§

fn sub(self, b: TrB) -> Self::Output

Performs the - operation. Read more
Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorATan2API<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceATan2API<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn atan2_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn atan2(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorATan2API<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceATan2API<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn atan2_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn atan2(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorATan2API<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceATan2API<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn atan2_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn atan2(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorATan2API<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceATan2API<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceATan2API<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn atan2_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn atan2(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorAddAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceAddAPI<T, T, T, DC> + DeviceLConsumeAddAPI<T, T, DA> + DeviceRConsumeAddAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Add<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn add_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn add(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<RA, DA, RB, DB, T, B> TensorAssignAPI<&TensorBase<Storage<RB, T, B>, DB>> for TensorAny<RA, T, B, DA>
where RA: DataMutAPI<Data = B::Raw>, RB: DataAPI<Data = B::Raw>, DA: DimAPI, DB: DimAPI, B: DeviceAPI<T> + OpAssignAPI<T, DA>,

Source§

fn assign_f(a: &mut Self, b: &TensorAny<RB, T, B, DB>) -> Result<()>

Source§

fn assign(a: &mut Self, b: TRB)

Source§

impl<RA, DA, RB, DB, T, B> TensorAssignAPI<TensorBase<Storage<RB, T, B>, DB>> for TensorAny<RA, T, B, DA>
where RA: DataMutAPI<Data = B::Raw>, RB: DataAPI<Data = B::Raw>, DA: DimAPI, DB: DimAPI, B: DeviceAPI<T> + OpAssignAPI<T, DA>,

Source§

fn assign_f(a: &mut Self, b: TensorAny<RB, T, B, DB>) -> Result<()>

Source§

fn assign(a: &mut Self, b: TRB)

Source§

impl<T, DA, DB, DC, B> TensorBitAndAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceBitAndAPI<T, T, T, DC> + DeviceLConsumeBitAndAPI<T, T, DA> + DeviceRConsumeBitAndAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: BitAnd<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn bitand_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn bitand(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorBitOrAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceBitOrAPI<T, T, T, DC> + DeviceLConsumeBitOrAPI<T, T, DA> + DeviceRConsumeBitOrAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: BitOr<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn bitor_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn bitor(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorBitXorAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceBitXorAPI<T, T, T, DC> + DeviceLConsumeBitXorAPI<T, T, DA> + DeviceRConsumeBitXorAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: BitXor<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn bitxor_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn bitxor(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorCopySignAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceCopySignAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn copysign_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn copysign(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorCopySignAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceCopySignAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn copysign_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn copysign(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorCopySignAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceCopySignAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn copysign_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn copysign(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorCopySignAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceCopySignAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceCopySignAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn copysign_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn copysign(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorDivAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceDivAPI<T, T, T, DC> + DeviceLConsumeDivAPI<T, T, DA> + DeviceRConsumeDivAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Div<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn div_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn div(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorEqualAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn equal_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorEqualAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn equal_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorFloorDivideAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceFloorDivideAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn floor_divide_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn floor_divide(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorFloorDivideAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceFloorDivideAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn floor_divide_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn floor_divide(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorFloorDivideAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceFloorDivideAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn floor_divide_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn floor_divide(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorFloorDivideAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceFloorDivideAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceFloorDivideAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn floor_divide_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn floor_divide(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorGreaterAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorGreaterAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorGreaterAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorGreaterAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorGreaterEqualAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_equal_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorGreaterEqualAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_equal_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorGreaterEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorGreaterEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceGreaterEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceGreaterEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn greater_equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn greater_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorHypotAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceHypotAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn hypot_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn hypot(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorHypotAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceHypotAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn hypot_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn hypot(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorHypotAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceHypotAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn hypot_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn hypot(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorHypotAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceHypotAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceHypotAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn hypot_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn hypot(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorLessAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn less(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorLessAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn less(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorLessAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn less(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorLessAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn less(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorLessEqualAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_equal_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn less_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorLessEqualAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_equal_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn less_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorLessEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn less_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorLessEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLessEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLessEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn less_equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn less_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorLogAddExpAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLogAddExpAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn log_add_exp_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn log_add_exp(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorLogAddExpAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLogAddExpAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn log_add_exp_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn log_add_exp(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorLogAddExpAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLogAddExpAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn log_add_exp_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn log_add_exp(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorLogAddExpAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceLogAddExpAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceLogAddExpAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn log_add_exp_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn log_add_exp(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorMaximumAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMaximumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn maximum_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn maximum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorMaximumAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMaximumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn maximum_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn maximum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorMaximumAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMaximumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn maximum_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn maximum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorMaximumAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMaximumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMaximumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn maximum_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn maximum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorMinimumAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMinimumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn minimum_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn minimum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorMinimumAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMinimumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn minimum_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn minimum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorMinimumAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMinimumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn minimum_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn minimum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorMinimumAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceMinimumAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceMinimumAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn minimum_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn minimum(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorMulAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceMulAPI<T, T, T, DC> + DeviceLConsumeMulAPI<T, T, DA> + DeviceRConsumeMulAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Mul<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn mul_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn mul(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorNotEqualAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceNotEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn not_equal_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn not_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorNotEqualAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceNotEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn not_equal_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn not_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorNotEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceNotEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn not_equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn not_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorNotEqualAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DeviceNotEqualAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DeviceNotEqualAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn not_equal_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn not_equal(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>> TensorPowAPI<&TensorBase<Storage<R, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DevicePowAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn pow_f(self, b: &TensorAny<R, TB, B, DB>) -> Result<Self::Output>

Source§

fn pow(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<RA, TA, DA, RB, TB, DB, B> TensorPowAPI<&TensorBase<Storage<RB, TB, B>, DB>> for &TensorAny<RA, TA, B, DA>
where RA: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>, RB: DataAPI<Data = <B as DeviceRawAPI<TB>>::Raw>, DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DevicePowAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn pow_f(self, b: &TensorAny<RB, TB, B, DB>) -> Result<Self::Output>

Source§

fn pow(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B, R: DataAPI<Data = <B as DeviceRawAPI<TA>>::Raw>> TensorPowAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for &TensorAny<R, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DevicePowAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn pow_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn pow(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<TA, DA, TB, DB, B> TensorPowAPI<TensorBase<Storage<DataRef<'_, <B as DeviceRawAPI<TB>>::Raw>, TB, B>, DB>> for TensorView<'_, TA, B, DA>
where DA: DimAPI + DimMaxAPI<DB>, DB: DimAPI, DA::Max: DimAPI, B: DevicePowAPI<TA, TB, DA::Max> + DeviceAPI<TA> + DeviceAPI<TB> + DeviceAPI<B::TOut> + DeviceCreationAnyAPI<B::TOut>,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<<B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut>>::Raw>, <B as DevicePowAPI<TA, TB, <DA as DimMaxAPI<DB>>::Max>>::TOut, B>, <DA as DimMaxAPI<DB>>::Max>

Source§

fn pow_f(self, b: TensorView<'_, TB, B, DB>) -> Result<Self::Output>

Source§

fn pow(self, b: TRB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorRemAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceRemAPI<T, T, T, DC> + DeviceLConsumeRemAPI<T, T, DA> + DeviceRConsumeRemAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Rem<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn rem_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn rem(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorShlAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceShlAPI<T, T, T, DC> + DeviceLConsumeShlAPI<T, T, DA> + DeviceRConsumeShlAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Shl<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn shl_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn shl(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorShrAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceShrAPI<T, T, T, DC> + DeviceLConsumeShrAPI<T, T, DA> + DeviceRConsumeShrAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Shr<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn shr_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn shr(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<T, DA, DB, DC, B> TensorSubAPI<TensorBase<Storage<DataCow<'_, <B as DeviceRawAPI<T>>::Raw>, T, B>, DB>> for TensorCow<'_, T, B, DA>
where DA: DimAPI + DimMaxAPI<DB, Max = DC> + DimIntoAPI<DC>, DB: DimAPI + DimMaxAPI<DA, Max = DC> + DimIntoAPI<DC>, DC: DimAPI + DimIntoAPI<DA> + DimIntoAPI<DB>, B: DeviceAPI<T> + DeviceCreationAnyAPI<T> + DeviceSubAPI<T, T, T, DC> + DeviceLConsumeSubAPI<T, T, DA> + DeviceRConsumeSubAPI<T, T, DB> + OpAssignAPI<T, DA> + OpAssignAPI<T, DB>, T: Sub<T, Output = T> + Clone, B::Raw: Clone,

Source§

type Output = TensorBase<Storage<DataOwned<<B as DeviceRawAPI<T>>::Raw>, T, B>, DC>

Source§

fn sub_f(a: Self, b: TensorCow<'_, T, B, DB>) -> Result<Self::Output>

Source§

fn sub(a: Self, b: TrB) -> Self::Output
where Self: Sized,

Source§

impl<R, D> Send for TensorBase<R, D>
where D: DimAPI, R: Send,

Source§

impl<R, D> Sync for TensorBase<R, D>
where D: DimAPI, R: Sync,

Source§

impl<R, D> TensorBaseAPI for TensorBase<R, D>
where D: DimAPI,

Auto Trait Implementations§

§

impl<S, D> Freeze for TensorBase<S, D>
where S: Freeze, D: Freeze, <D as DimBaseAPI>::Stride: Freeze,

§

impl<S, D> RefUnwindSafe for TensorBase<S, D>

§

impl<S, D> Unpin for TensorBase<S, D>
where S: Unpin, D: Unpin, <D as DimBaseAPI>::Stride: Unpin,

§

impl<S, D> UnwindSafe for TensorBase<S, D>

Blanket Implementations§

Source§

impl<Rhs, Lhs, Output> AddByRef<Rhs> for Lhs
where &'a Lhs: for<'a> Add<&'a Rhs, Output = Output>,

Source§

type Output = Output

Source§

fn add_by_ref(&self, rhs: &Rhs) -> <Lhs as AddByRef<Rhs>>::Output

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> ByRef<T> for T

Source§

fn by_ref(&self) -> &T

Source§

impl<Rhs, Lhs, Output> DivByRef<Rhs> for Lhs
where &'a Lhs: for<'a> Div<&'a Rhs, Output = Output>,

Source§

type Output = Output

Source§

fn div_by_ref(&self, rhs: &Rhs) -> <Lhs as DivByRef<Rhs>>::Output

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<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<Rhs, Lhs, Output> MulByRef<Rhs> for Lhs
where &'a Lhs: for<'a> Mul<&'a Rhs, Output = Output>,

Source§

type Output = Output

Source§

fn mul_by_ref(&self, rhs: &Rhs) -> <Lhs as MulByRef<Rhs>>::Output

Source§

impl<T, Output> NegByRef for T
where &'a T: for<'a> Neg<Output = Output>,

Source§

type Output = Output

Source§

fn neg_by_ref(&self) -> <T as NegByRef>::Output

Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<Rhs, Lhs, Output> SubByRef<Rhs> for Lhs
where &'a Lhs: for<'a> Sub<&'a Rhs, Output = Output>,

Source§

type Output = Output

Source§

fn sub_by_ref(&self, rhs: &Rhs) -> <Lhs as SubByRef<Rhs>>::Output

Source§

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

Source§

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>,

Source§

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>,

Source§

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<T> ValWriteAPI<T> for T

Source§

fn write(&mut self, val: T) -> &mut T

Source§

impl<T, Rhs> NumAssignOps<Rhs> for T
where T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,

Source§

impl<T, Rhs, Output> NumOps<Rhs, Output> for T
where T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,

Source§

impl<T, Base> RefNum<Base> for T
where T: NumOps<Base, Base> + for<'r> NumOps<&'r Base, Base>,