reorder a few things (#1915)

* reorder a few things

* huh, that has to be there

* move apply shapetracker

* BufferOps

* only for type checking
This commit is contained in:
George Hotz
2023-09-25 10:17:21 +08:00
committed by GitHub
parent 25a767cd5d
commit c907efbf4a
10 changed files with 96 additions and 87 deletions

View File

@@ -266,9 +266,9 @@ from tinygrad.tensor import Tensor
result = Tensor(2).realize() + Tensor(3).realize()
# use the real Linearizer to linearize 2+3
from tinygrad.lazy import _replace_loadops
from tinygrad.lazy import _replace_bufferops
from tinygrad.codegen.linearizer import Linearizer
op, _ = _replace_loadops(result.lazydata.op)
op, _ = _replace_bufferops(result.lazydata.op)
linearizer = Linearizer(op)
linearizer.linearize()