Skip to content
Discussion options

You must be logged in to vote

I suspect what you're looking for is jax.lax.stop_gradient:

def f(x):
  a = lax.stop_gradient(helperFunc(x))
  return jnp.squeeze(jnp.power(x, 2) + a)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by jdongg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants