Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/tinygrad/tinygrad
/ test_uniform_gradient
Method
test_uniform_gradient
test/null/test_gradient.py:77–80 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
75
assert x.uop.is_realized
76
77
def
test_uniform_gradient(self):
78
x = Tensor.uniform(16, 3, 3, 3).realize()
79
y = x * 2
80
y.sum().gradient(x)[0].realize()
81
82
if
__name__ ==
'__main__'
:
83
unittest.main()
Callers
nothing calls this directly
Calls
4
realize
Method · 0.80
uniform
Method · 0.80
gradient
Method · 0.80
sum
Method · 0.80
Tested by
no test coverage detected