#[non_exhaustive]pub enum ParameterError {
WeightRank {
found: usize,
expected: usize,
},
Groups {
found: i64,
},
ChannelGroupDivisibility {
channels: usize,
groups: i64,
},
ExtentArity {
field: &'static str,
expected: &'static str,
found: usize,
},
ExtentRank {
field: &'static str,
found: usize,
},
ExtentDType {
field: &'static str,
dtype: &'static str,
},
ExtentPositive {
field: &'static str,
index: usize,
value: i64,
},
ExtentNonNegative {
field: &'static str,
index: usize,
value: i64,
},
BiasLength {
found: usize,
expected: usize,
},
BiasRank {
found: usize,
},
WeightExtentPositive {
axis: usize,
},
}Expand description
Local convolution or pooling parameter invariant that failed.
Each variant is unambiguous from the node’s own fields (no whole-graph
shape inference). Returned inside NirError::InvalidNodeParameters.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
WeightRank
Weight tensor rank does not match the convolution kind.
Fields
Groups
groups is not a positive count.
ChannelGroupDivisibility
Output-channel count is not divisible by groups.
ExtentArity
A stride, dilation, padding, or pooling window has the wrong length.
Fields
ExtentRank
A pooling window tensor is not a scalar or a 1-D vector of extents.
Fields
ExtentDType
A pooling window tensor is not an integer payload.
Fields
ExtentPositive
A stride, dilation, or kernel extent is not strictly positive.
Fields
ExtentNonNegative
An explicit padding extent is negative.
Fields
BiasLength
Bias element count does not match the convolution’s output channels.
BiasRank
Bias tensor is not rank-1.
WeightExtentPositive
A weight tensor axis extent is not strictly positive.
Trait Implementations§
Source§impl Clone for ParameterError
impl Clone for ParameterError
Source§fn clone(&self) -> ParameterError
fn clone(&self) -> ParameterError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ParameterError
impl Debug for ParameterError
Source§impl Display for ParameterError
impl Display for ParameterError
impl Eq for ParameterError
Source§impl Error for ParameterError
impl Error for ParameterError
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()
Source§impl PartialEq for ParameterError
impl PartialEq for ParameterError
impl StructuralPartialEq for ParameterError
Auto Trait Implementations§
impl Freeze for ParameterError
impl RefUnwindSafe for ParameterError
impl Send for ParameterError
impl Sync for ParameterError
impl Unpin for ParameterError
impl UnsafeUnpin for ParameterError
impl UnwindSafe for ParameterError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.