[−][src]Struct tract_core::dim::TDim
Methods
impl TDim
[src]
impl TDim
pub fn is_one(&self) -> bool
[src]
pub fn is_one(&self) -> bool
pub fn s() -> TDim
[src]
pub fn s() -> TDim
pub fn stream() -> TDim
[src]
pub fn stream() -> TDim
pub fn as_const(&self) -> Option<i64>
[src]
pub fn as_const(&self) -> Option<i64>
pub fn reduce(&mut self)
[src]
pub fn reduce(&mut self)
pub fn eval(&self, s: i64) -> Option<i64>
[src]
pub fn eval(&self, s: i64) -> Option<i64>
pub fn is_stream(&self) -> bool
[src]
pub fn is_stream(&self) -> bool
pub fn to_integer(&self) -> TractResult<i64>
[src]
pub fn to_integer(&self) -> TractResult<i64>
pub fn div_ceil(&self, other: TDim) -> TDim
[src]
pub fn div_ceil(&self, other: TDim) -> TDim
Trait Implementations
impl Output for TDim
[src]
impl Output for TDim
fn into_wrapped(source: TDim) -> Wrapped
[src]
fn into_wrapped(source: TDim) -> Wrapped
Wraps the fact in the Wrapped type.
fn from_wrapped(wrapped: Wrapped) -> TractResult<TDim>
[src]
fn from_wrapped(wrapped: Wrapped) -> TractResult<TDim>
Retrieves the fact from the Wrapped type. Panics if wrapped doesn't have the right constructor. Read more
fn wrap(self) -> Wrapped
[src]
fn wrap(self) -> Wrapped
Wraps self in the Wrapped type.
impl IntoExp<GenericFact<TDim>> for TDim
[src]
impl IntoExp<GenericFact<TDim>> for TDim
impl DimLike for TDim
[src]
impl DimLike for TDim
fn to_integer(&self) -> TractResult<i64>
[src]
fn to_integer(&self) -> TractResult<i64>
fn div_ceil(&self, other: usize) -> Self
[src]
fn div_ceil(&self, other: usize) -> Self
impl Datum for TDim
[src]
impl Datum for TDim
fn name() -> &'static str
[src]
fn name() -> &'static str
fn datum_type() -> DatumType
[src]
fn datum_type() -> DatumType
fn tensor_into_array(m: Tensor) -> TractResult<ArrayD<Self>>
[src]
fn tensor_into_array(m: Tensor) -> TractResult<ArrayD<Self>>
fn tensor_to_view(m: &Tensor) -> TractResult<ArrayViewD<Self>>
[src]
fn tensor_to_view(m: &Tensor) -> TractResult<ArrayViewD<Self>>
fn tensor_to_view_mut(m: &mut Tensor) -> TractResult<ArrayViewMutD<Self>>
[src]
fn tensor_to_view_mut(m: &mut Tensor) -> TractResult<ArrayViewMutD<Self>>
fn array_into_tensor(m: ArrayD<Self>) -> Tensor
[src]
fn array_into_tensor(m: ArrayD<Self>) -> Tensor
fn tensor_cast_to_array(m: &Tensor) -> TractResult<MaybeOwnedArray<TDim>>
[src]
fn tensor_cast_to_array(m: &Tensor) -> TractResult<MaybeOwnedArray<TDim>>
impl Default for TDim
[src]
impl Default for TDim
impl PartialEq<TDim> for TDim
[src]
impl PartialEq<TDim> for TDim
fn eq(&self, other: &TDim) -> bool
[src]
fn eq(&self, other: &TDim) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &TDim) -> bool
[src]
fn ne(&self, other: &TDim) -> bool
This method tests for !=
.
impl<I: AsPrimitive<i64>> From<I> for TDim
[src]
impl<I: AsPrimitive<i64>> From<I> for TDim
impl From<TDim> for Tensor
[src]
impl From<TDim> for Tensor
impl Clone for TDim
[src]
impl Clone for TDim
fn clone(&self) -> TDim
[src]
fn clone(&self) -> TDim
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for TDim
[src]
impl Copy for TDim
impl Eq for TDim
[src]
impl Eq for TDim
impl Debug for TDim
[src]
impl Debug for TDim
fn fmt(&self, fmt: &mut Formatter) -> Result
[src]
fn fmt(&self, fmt: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Sub<TDim> for TDim
[src]
impl Sub<TDim> for TDim
type Output = Self
The resulting type after applying the -
operator.
fn sub(self, rhs: TDim) -> Self
[src]
fn sub(self, rhs: TDim) -> Self
Performs the -
operation.
impl<I: AsPrimitive<i64>> Sub<I> for TDim
[src]
impl<I: AsPrimitive<i64>> Sub<I> for TDim
type Output = Self
The resulting type after applying the -
operator.
fn sub(self, rhs: I) -> Self
[src]
fn sub(self, rhs: I) -> Self
Performs the -
operation.
impl Add<TDim> for TDim
[src]
impl Add<TDim> for TDim
type Output = Self
The resulting type after applying the +
operator.
fn add(self, rhs: TDim) -> Self
[src]
fn add(self, rhs: TDim) -> Self
Performs the +
operation.
impl<I: AsPrimitive<i64>> Add<I> for TDim
[src]
impl<I: AsPrimitive<i64>> Add<I> for TDim
type Output = Self
The resulting type after applying the +
operator.
fn add(self, rhs: I) -> Self
[src]
fn add(self, rhs: I) -> Self
Performs the +
operation.
impl Mul<TDim> for TDim
[src]
impl Mul<TDim> for TDim
type Output = Self
The resulting type after applying the *
operator.
fn mul(self, rhs: TDim) -> Self
[src]
fn mul(self, rhs: TDim) -> Self
Performs the *
operation.
impl<I: AsPrimitive<i64>> Mul<I> for TDim
[src]
impl<I: AsPrimitive<i64>> Mul<I> for TDim
type Output = Self
The resulting type after applying the *
operator.
fn mul(self, rhs: I) -> Self
[src]
fn mul(self, rhs: I) -> Self
Performs the *
operation.
impl Div<TDim> for TDim
[src]
impl Div<TDim> for TDim
type Output = Self
The resulting type after applying the /
operator.
fn div(self, rhs: TDim) -> TDim
[src]
fn div(self, rhs: TDim) -> TDim
Performs the /
operation.
impl<I: AsPrimitive<i64>> Div<I> for TDim
[src]
impl<I: AsPrimitive<i64>> Div<I> for TDim
type Output = Self
The resulting type after applying the /
operator.
fn div(self, rhs: I) -> Self
[src]
fn div(self, rhs: I) -> Self
Performs the /
operation.
impl Rem<TDim> for TDim
[src]
impl Rem<TDim> for TDim
type Output = Self
The resulting type after applying the %
operator.
fn rem(self, rhs: TDim) -> TDim
[src]
fn rem(self, rhs: TDim) -> TDim
Performs the %
operation.
impl<I: AsPrimitive<i64>> Rem<I> for TDim
[src]
impl<I: AsPrimitive<i64>> Rem<I> for TDim
type Output = Self
The resulting type after applying the %
operator.
fn rem(self, rhs: I) -> Self
[src]
fn rem(self, rhs: I) -> Self
Performs the %
operation.
impl Neg for TDim
[src]
impl Neg for TDim
type Output = Self
The resulting type after applying the -
operator.
fn neg(self) -> Self
[src]
fn neg(self) -> Self
Performs the unary -
operation.
impl AddAssign<TDim> for TDim
[src]
impl AddAssign<TDim> for TDim
fn add_assign(&mut self, rhs: TDim)
[src]
fn add_assign(&mut self, rhs: TDim)
Performs the +=
operation.
impl SubAssign<TDim> for TDim
[src]
impl SubAssign<TDim> for TDim
fn sub_assign(&mut self, rhs: TDim)
[src]
fn sub_assign(&mut self, rhs: TDim)
Performs the -=
operation.
impl MulAssign<TDim> for TDim
[src]
impl MulAssign<TDim> for TDim
fn mul_assign(&mut self, rhs: TDim)
[src]
fn mul_assign(&mut self, rhs: TDim)
Performs the *=
operation.
impl DivAssign<TDim> for TDim
[src]
impl DivAssign<TDim> for TDim
fn div_assign(&mut self, rhs: TDim)
[src]
fn div_assign(&mut self, rhs: TDim)
Performs the /=
operation.
impl RemAssign<TDim> for TDim
[src]
impl RemAssign<TDim> for TDim
fn rem_assign(&mut self, rhs: TDim)
[src]
fn rem_assign(&mut self, rhs: TDim)
Performs the %=
operation.
impl FromIterator<TDim> for ShapeFact
[src]
impl FromIterator<TDim> for ShapeFact
fn from_iter<I: IntoIterator<Item = TDim>>(iter: I) -> ShapeFact
[src]
fn from_iter<I: IntoIterator<Item = TDim>>(iter: I) -> ShapeFact
Converts an iterator over usize into a closed shape.
impl Zero for TDim
[src]
impl Zero for TDim
fn zero() -> Self
[src]
fn zero() -> Self
Returns the additive identity element of Self
, 0
. Read more
fn is_zero(&self) -> bool
[src]
fn is_zero(&self) -> bool
Returns true
if self
is equal to the additive identity.
impl One for TDim
[src]
impl One for TDim
Auto Trait Implementations
Blanket Implementations
impl<T, E> IntoExp for E where
E: 'static + TExp<T>,
[src]
impl<T, E> IntoExp for E where
E: 'static + TExp<T>,
impl<I> ToDim for I where
I: Into<TDim>,
[src]
impl<I> ToDim for I where
I: Into<TDim>,
impl<PB, Tract> ToTract for PB where
Tract: Tractify<PB>,
[src]
impl<PB, Tract> ToTract for PB where
Tract: Tractify<PB>,
fn tractify(&Self) -> Result<Tract, TractError>
[src]
fn tractify(&Self) -> Result<Tract, TractError>
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
type Owned = T
fn to_owned(&self) -> T
[src]
fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
fn clone_into(&self, target: &mut T)
[src]
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
try_from
)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
try_from
)Performs the conversion.
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more
impl<T> LinalgScalar for T where
T: One<Output = T> + Add<T, Output = T> + Sub<T, Output = T> + 'static + Mul<T> + Copy + Div<T, Output = T> + Zero,
[src]
impl<T> LinalgScalar for T where
T: One<Output = T> + Add<T, Output = T> + Sub<T, Output = T> + 'static + Mul<T> + Copy + Div<T, Output = T> + Zero,
impl<T, Rhs, Output> NumOps for T where
T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,
[src]
impl<T, Rhs, Output> NumOps for T where
T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,
impl<T, Rhs> NumAssignOps for T where
T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,
[src]
impl<T, Rhs> NumAssignOps for T where
T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,
impl<T> Clone for T where
T: Clone,
[src]
impl<T> Clone for T where
T: Clone,
impl<T> Downcast for T where
T: Any,
[src]
impl<T> Downcast for T where
T: Any,
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
[src]
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
Convert Box<Trait>
(where Trait: Downcast
) to Box<Any>
. Box<Any>
can then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read more
fn as_any(&self) -> &(dyn Any + 'static)
[src]
fn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot generate &Any
's vtable from &Trait
's. Read more
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
[src]
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot generate &mut Any
's vtable from &mut Trait
's. Read more