MCPcopy Create free account
hub / github.com/PythonOT/POT / fun

Function fun

test/test_backend.py:800–802  ·  view source on GitHub ↗
(a, b, d)

Source from the content-addressed store, hash-verified

798 with jax.checking_leaks():
799
800 def fun(a, b, d):
801 val = b * nx.sum(a**4) + d
802 return nx.set_gradients(val, (a, b, d), (a, b, 2 * d))
803
804 grad_val = jax.grad(fun, argnums=(0, 1, 2))(v, c, e)
805

Callers 1

test_gradients_backendsFunction · 0.70

Calls 2

sumMethod · 0.45
set_gradientsMethod · 0.45

Tested by

no test coverage detected