pub enum LinearQuantizeCodecError {
MismatchedEncodeDType {
configured: LinearQuantizeDType,
provided: AnyArrayDType,
},
NonFiniteData,
HeaderEncodeFailed {
source: LinearQuantizeHeaderError,
},
EncodedDataNotOneDimensional {
shape: Vec<usize>,
},
HeaderDecodeFailed {
source: LinearQuantizeHeaderError,
},
DecodeInvalidShapeHeader {
source: ShapeError,
},
InvalidEncodedDType {
dtype: AnyArrayDType,
},
MismatchedDecodeIntoDtype {
configured: LinearQuantizeDType,
provided: AnyArrayDType,
},
MismatchedDecodeIntoShape {
decoded: Vec<usize>,
provided: Vec<usize>,
},
}Expand description
Errors that may occur when applying the LinearQuantizeCodec.
Variants§
MismatchedEncodeDType
LinearQuantizeCodec cannot encode the provided dtype which differs
from the configured dtype
Fields
configured: LinearQuantizeDTypeDtype of the configured dtype
provided: AnyArrayDTypeDtype of the provided array from which the data is to be encoded
NonFiniteData
LinearQuantizeCodec does not support non-finite (infinite or NaN) floating
point data
HeaderEncodeFailed
LinearQuantizeCodec failed to encode the header
Fields
source: LinearQuantizeHeaderErrorOpaque source error
EncodedDataNotOneDimensional
LinearQuantizeCodec can only decode one-dimensional arrays but
received an array of a different shape
HeaderDecodeFailed
LinearQuantizeCodec failed to decode the header
Fields
source: LinearQuantizeHeaderErrorOpaque source error
DecodeInvalidShapeHeader
LinearQuantizeCodec decoded an invalid array shape header which does
not fit the decoded data
Fields
source: ShapeErrorSource error
InvalidEncodedDType
LinearQuantizeCodec cannot decode the provided dtype
Fields
dtype: AnyArrayDTypeDtype of the provided array from which the data is to be decoded
MismatchedDecodeIntoDtype
LinearQuantizeCodec cannot decode the provided dtype which differs
from the configured dtype
Fields
configured: LinearQuantizeDTypeDtype of the configured dtype
provided: AnyArrayDTypeDtype of the provided array into which the data is to be decoded
MismatchedDecodeIntoShape
LinearQuantizeCodec cannot decode the decoded array into the provided
array of a different shape