From 7adffafedab0db2e842b50b5f9fd734cc704544e Mon Sep 17 00:00:00 2001 From: laurent Date: Wed, 21 Jun 2023 14:29:48 +0100 Subject: Abstract the gradient storage. --- tests/tensor_tests.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/tensor_tests.rs') diff --git a/tests/tensor_tests.rs b/tests/tensor_tests.rs index 01f6f66c..fb2d84d9 100644 --- a/tests/tensor_tests.rs +++ b/tests/tensor_tests.rs @@ -2,7 +2,7 @@ use candle::{DType, Device, Result, Tensor}; #[test] fn zeros() -> Result<()> { - let tensor = Tensor::zeros((5, 2), DType::F32, Device::Cpu); + let tensor = Tensor::zeros((5, 2), DType::F32, Device::Cpu)?; let (dim1, dim2) = tensor.shape().r2()?; assert_eq!(dim1, 5); assert_eq!(dim2, 2); -- cgit v1.2.3