pub enum ReduceError {
Show 13 variants
PlanesUnavailable,
CubeCountTooLarge,
Validation {
details: &'static str,
},
ImprecisePlaneDim,
InvalidAxis {
axis: usize,
rank: usize,
},
ReduceAxisTooSmall {
axis_length: usize,
k: usize,
},
MismatchOutputShape {
expected_shape: Vec<usize>,
output_shape: Vec<usize>,
},
MismatchIndicesShape {
values_shape: Vec<usize>,
indices_shape: Vec<usize>,
},
MismatchIndicesStrides {
values_strides: Vec<usize>,
indices_strides: Vec<usize>,
},
IndicesUnsupported {
operation: &'static str,
},
MissingAtomicAdd(ElemType),
SharedMemoryOverflow {
requested: usize,
available: usize,
},
Launch(LaunchError),
}Expand description
This error should be caught and properly handled.
Variants§
Indicate that the hardware / API doesn’t support SIMT plane instructions.
CubeCountTooLarge
When the cube count is bigger than the max supported.
Validation
A generic validation error
ImprecisePlaneDim
Indicate that min_plane_dim != max_plane_dim, thus the exact plane_dim is not fixed.
InvalidAxis
Indicate the axis is too large.
ReduceAxisTooSmall
Indicate that the shape of the input tensor is too small for the given input and axis.
MismatchOutputShape
Indicate that the shape of the output tensor is invalid for the given input and axis.
MismatchIndicesShape
Indicate that the indices output shape does not match the values output shape.
MismatchIndicesStrides
Indicate that the indices output strides do not match the values output strides.
IndicesUnsupported
Indicate the operation cannot report indices alongside its values.
MissingAtomicAdd(ElemType)
Indicate that we can’t launch a shared sum because the atomic addition is not supported.
The selected blueprint stages more accumulators in shared memory than the device allows.
Launch(LaunchError)
An error happened during launch.
Trait Implementations§
Source§impl Clone for ReduceError
impl Clone for ReduceError
Source§impl Debug for ReduceError
impl Debug for ReduceError
Source§impl Display for ReduceError
impl Display for ReduceError
Source§impl Error for ReduceError
impl Error for ReduceError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for ReduceError
impl RefUnwindSafe for ReduceError
impl Send for ReduceError
impl Sync for ReduceError
impl Unpin for ReduceError
impl UnsafeUnpin for ReduceError
impl UnwindSafe for ReduceError
Blanket Implementations§
impl<T> AnyError for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneExpand for Twhere
T: Clone,
impl<T> CloneExpand for Twhere
T: Clone,
fn __expand_clone_method(&self, _: &Scope) -> T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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> ⓘ
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> ⓘ
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