A high-performance inference engine for AI models
Reduce Memory (#216)
eugene46f237a9340c
diff --git a/crates/uzu/src/forward_pass/scratch_buffers.rs b/crates/uzu/src/forward_pass/scratch_buffers.rsindex 6789482f1..a616571aa 100644--- a/crates/uzu/src/forward_pass/scratch_buffers.rs+++ b/crates/uzu/src/forward_pass/scratch_buffers.rs@@ -80,7 +80,7 @@ impl<B: Backend> ScratchBuffers<B> {) -> Self {// Helper closure for allocationlet alloc = |shape: &[usize], dtype: DataType, label: &str| -> ArrayCell<B> {- let array = context.create_array(shape, dtype, &format!("scratch_buffers_{label}"));+ let array = context.create_array_uninitialized(shape, dtype, &format!("scratch_buffers_{label}"));RefCell::new(array)};