From b9864e135729283fab450abaff16982cc96552be Mon Sep 17 00:00:00 2001 From: Laurent Mazare Date: Tue, 8 Aug 2023 22:15:18 +0200 Subject: [PATCH] Fix size-in-bytes for u8. (#351) --- candle-core/src/dtype.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/candle-core/src/dtype.rs b/candle-core/src/dtype.rs index 5dc74827..92929748 100644 --- a/candle-core/src/dtype.rs +++ b/candle-core/src/dtype.rs @@ -43,7 +43,7 @@ impl DType { pub fn size_in_bytes(&self) -> usize { match self { - Self::U8 => 4, + Self::U8 => 1, Self::U32 => 4, Self::BF16 => 2, Self::F16 => 2,