Trait burn::tensor::quantization::QTensorPrimitive

pub trait QTensorPrimitive {
    // Required methods
    fn scheme(&self) -> &QuantizationScheme;
    fn strategy(&self) -> QuantizationStrategy;
}
Expand description

Quantized tensor primitive.

Required Methods§

fn scheme(&self) -> &QuantizationScheme

Returns the quantization scheme for the given tensor.

fn strategy(&self) -> QuantizationStrategy

Returns the quantization strategy for the given tensor.

§Remarks

Retrieving the quantization strategy with its corresponding parameters might require synchronization on the backend.

Implementations on Foreign Types§

§

impl<R> QTensorPrimitive for QFusionTensor<R>
where R: FusionRuntime,

Implementors§

§

impl QTensorPrimitive for CandleQTensor

§

impl<Q> QTensorPrimitive for TchQTensor<Q>
where Q: QuantElement,

§

impl<Q> QTensorPrimitive for NdArrayQTensor<Q>
where Q: QuantElement,