From e4e9b25a8013c9f217bf5486570fce9ca41a1fa6 Mon Sep 17 00:00:00 2001 From: qazal Date: Thu, 5 Dec 2024 13:24:17 +0200 Subject: [PATCH] uop is immutable --- examples/openpilot/compile2.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/openpilot/compile2.py b/examples/openpilot/compile2.py index d862bf203c..825544621e 100644 --- a/examples/openpilot/compile2.py +++ b/examples/openpilot/compile2.py @@ -149,7 +149,8 @@ if __name__ == "__main__": }) if needs_load: t = Tensor.empty(b.dtype.shape, dtype=b.dtype) - t.lazydata.buffer = b + # TODO: what does this do? uop is immutable + #t.lazydata.buffer = b data = t.cast(dtypes.float32).pad(((0, row_pitch//(4*base_dtype.itemsize)-b.dtype.shape[0]), (0,0), (0,0))).contiguous().numpy() # NOTE: this cast must be done in numpy for platforms that don't support half if base_dtype == dtypes.float16: data = data.astype(np.float16)