pub enum Platform {
Host(Host),
}Expand description
The global platform, responsible for delegating to specific hardware platforms
Variants§
Trait Implementations§
Source§impl<A, T> ConstructConcat<A, T> for Platform
impl<A, T> ConstructConcat<A, T> for Platform
Source§impl<T: Number + PartialOrd> ConstructRange<T> for Platform
impl<T: Number + PartialOrd> ConstructRange<T> for Platform
Source§impl<A, T> ElementwiseAbs<A, T> for Platform
impl<A, T> ElementwiseAbs<A, T> for Platform
Source§impl<L, R, T> ElementwiseBoolean<L, R, T> for Platform
impl<L, R, T> ElementwiseBoolean<L, R, T> for Platform
Source§impl<A: Access<T>, T: Number> ElementwiseBooleanScalar<A, T> for Platform
impl<A: Access<T>, T: Number> ElementwiseBooleanScalar<A, T> for Platform
type Op = Scalar<A, T, u8>
fn and_scalar( self, left: A, right: T, ) -> Result<AccessOp<Self::Op, Self>, Error>
fn or_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>
fn xor_scalar( self, left: A, right: T, ) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<L, R, T> ElementwiseCompare<L, R, T> for Platform
impl<L, R, T> ElementwiseCompare<L, R, T> for Platform
type Op = Dual<L, R, T, u8>
fn eq(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>
fn ge(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn gt(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn le(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn lt(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn ne(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<A: Access<T>, T: Number> ElementwiseCompareScalar<A, T> for Platform
impl<A: Access<T>, T: Number> ElementwiseCompareScalar<A, T> for Platform
type Op = Scalar<A, T, u8>
fn eq_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>
fn ge_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn gt_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn le_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn lt_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn ne_scalar(self, left: A, right: T) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<L, R, T> ElementwiseDual<L, R, T> for Platform
impl<L, R, T> ElementwiseDual<L, R, T> for Platform
type Op = Dual<L, R, T, T>
fn add(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>
fn div(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>
fn log(self, arg: L, base: R) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Float,
fn mul(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>
fn pow(self, arg: L, exp: R) -> Result<AccessOp<Self::Op, Self>, Error>
fn rem(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn sub(self, left: L, right: R) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<A: Access<T>, T: Number> ElementwiseScalar<A, T> for Platform
impl<A: Access<T>, T: Number> ElementwiseScalar<A, T> for Platform
type Op = Scalar<A, T, T>
fn add_scalar( self, left: A, right: T, ) -> Result<AccessOp<Self::Op, Self>, Error>
fn div_scalar( self, left: A, right: T, ) -> Result<AccessOp<Self::Op, Self>, Error>
fn log_scalar(self, arg: A, base: T) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Float,
fn mul_scalar( self, left: A, right: T, ) -> Result<AccessOp<Self::Op, Self>, Error>
fn pow_scalar(self, arg: A, exp: T) -> Result<AccessOp<Self::Op, Self>, Error>
fn rem_scalar(
self,
left: A,
right: T,
) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn sub_scalar( self, left: A, right: T, ) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<A: Access<T>, T: Float> ElementwiseTrig<A, T> for Platform
impl<A: Access<T>, T: Float> ElementwiseTrig<A, T> for Platform
type Op = Unary<A, T, T>
fn sin(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn asin(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn sinh(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn cos(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn acos(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn cosh(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn tan(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn atan(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
fn tanh(self, access: A) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<A, L, R, T> GatherCond<A, L, R, T> for Platform
impl<A, L, R, T> GatherCond<A, L, R, T> for Platform
Source§impl<L, R, T> LinAlgDual<L, R, T> for Platform
impl<L, R, T> LinAlgDual<L, R, T> for Platform
Source§impl PlatformInstance for Platform
Available on non-crate feature opencl only.
impl PlatformInstance for Platform
Available on non-crate feature
opencl only.Source§impl<A, T> ReduceAll<A, T> for Platform
impl<A, T> ReduceAll<A, T> for Platform
fn all(self, access: A) -> Result<bool, Error>
fn any(self, access: A) -> Result<bool, Error>
fn max(self, access: A) -> Result<T, Error>where
T: Real,
fn min(self, access: A) -> Result<T, Error>where
T: Real,
fn product(self, access: A) -> Result<T, Error>
fn sum(self, access: A) -> Result<T, Error>
Source§impl<A: Access<T>, T: Number> ReduceAxes<A, T> for Platform
impl<A: Access<T>, T: Number> ReduceAxes<A, T> for Platform
type Op = Reduce<A, T>
fn max(
self,
access: A,
stride: usize,
) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn min(
self,
access: A,
stride: usize,
) -> Result<AccessOp<Self::Op, Self>, Error>where
T: Real,
fn product( self, access: A, stride: usize, ) -> Result<AccessOp<Self::Op, Self>, Error>
fn sum( self, access: A, stride: usize, ) -> Result<AccessOp<Self::Op, Self>, Error>
Source§impl<A: Access<T>, T: Number> Transform<A, T> for Platform
impl<A: Access<T>, T: Number> Transform<A, T> for Platform
type Broadcast = View<A, T>
type Flip = Flip<A, T>
type Slice = Slice<A, T>
type Transpose = View<A, T>
fn broadcast( self, access: A, shape: Shape, broadcast: Shape, ) -> Result<AccessOp<Self::Broadcast, Self>, Error>
fn flip( self, access: A, shape: Shape, axis: usize, ) -> Result<AccessOp<Self::Flip, Self>, Error>
fn slice( self, access: A, shape: &[usize], range: Range, ) -> Result<AccessOp<Self::Slice, Self>, Error>
fn transpose( self, access: A, shape: Shape, permutation: Axes, ) -> Result<AccessOp<Self::Transpose, Self>, Error>
impl Copy for Platform
impl Eq for Platform
impl StructuralPartialEq for Platform
Auto Trait Implementations§
impl Freeze for Platform
impl RefUnwindSafe for Platform
impl Send for Platform
impl Sync for Platform
impl Unpin for Platform
impl UnwindSafe for Platform
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<F> Match for F
impl<F> Match for F
Source§fn matches<T>(&self) -> boolwhere
T: TryCastFrom<Self>,
fn matches<T>(&self) -> boolwhere
T: TryCastFrom<Self>,
Returns
true if self can be cast into the target type T.Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<F, T> TryCastFrom<F> for Twhere
T: CastFrom<F>,
impl<F, T> TryCastFrom<F> for Twhere
T: CastFrom<F>,
Source§fn can_cast_from(_: &F) -> bool
fn can_cast_from(_: &F) -> bool
Test if
value can be cast into Self.Source§fn opt_cast_from(f: F) -> Option<T>
fn opt_cast_from(f: F) -> Option<T>
Returns
Some(Self) if the source value can be cast into Self, otherwise None.Source§impl<F, T> TryCastInto<T> for Fwhere
T: TryCastFrom<F>,
impl<F, T> TryCastInto<T> for Fwhere
T: TryCastFrom<F>,
Source§fn can_cast_into(&self) -> bool
fn can_cast_into(&self) -> bool
Test if
self can be cast into T.Source§fn opt_cast_into(self) -> Option<T>
fn opt_cast_into(self) -> Option<T>
Returns
Some(T) if self can be cast into T, otherwise None.Source§fn try_cast_into<Err, OnErr>(self, on_err: OnErr) -> Result<T, Err>where
OnErr: FnOnce(&Self) -> Err,
fn try_cast_into<Err, OnErr>(self, on_err: OnErr) -> Result<T, Err>where
OnErr: FnOnce(&Self) -> Err,
Returns
Ok(T) if self can be cast into T, otherwise calls on_err.