summaryrefslogtreecommitdiff
path: root/candle-core/src/quantized/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'candle-core/src/quantized/mod.rs')
-rw-r--r--candle-core/src/quantized/mod.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/candle-core/src/quantized/mod.rs b/candle-core/src/quantized/mod.rs
index a0ed5b4d..a334b2c1 100644
--- a/candle-core/src/quantized/mod.rs
+++ b/candle-core/src/quantized/mod.rs
@@ -147,11 +147,11 @@ impl QTensor {
}
}
-pub struct QMatMul(std::sync::Arc<Box<dyn crate::CustomOp1>>);
+pub struct QMatMul(QTensor);
impl QMatMul {
pub fn from_qtensor(qtensor: QTensor) -> Self {
- Self(std::sync::Arc::new(Box::new(qtensor)))
+ Self(qtensor)
}
}
@@ -196,6 +196,6 @@ impl crate::CustomOp1 for QTensor {
impl QMatMul {
pub fn forward(&self, xs: &Tensor) -> Result<Tensor> {
- xs.custom_op1_arc(self.0.clone())
+ xs.apply_op1_no_bwd(&self.0)
}
}