mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-06-24 02:14:17 +00:00
Interpreted cleanups (#2312)
* move the compiler out of ops * don't return realized * var_vals filter, fix custom * typing
This commit is contained in:
parent
123a0b86b2
commit
4da2ddea6e
9 changed files with 85 additions and 86 deletions
|
|
@ -28,7 +28,7 @@ def atan2_gpu(ret:LazyBuffer, a:LazyBuffer, b:LazyBuffer):
|
|||
return ret.realized
|
||||
|
||||
def atan2_cpu(ret:LazyBuffer, a:LazyBuffer, b:LazyBuffer):
|
||||
return Device[ret.device].from_underlying(np.arctan2(a.realized._buf, b.realized._buf))
|
||||
return Device[ret.device].buffer.fromCPU(np.arctan2(a.realized._buf, b.realized._buf))
|
||||
|
||||
# *** second, we write the ATan2 mlop ***
|
||||
# NOTE: The derivative of atan2 doesn't need a custom op! https://www.liquisearch.com/atan2/derivative
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue