Oh I missed that. You can’t differentiate that in isolation then. You have to differentiate the full process if you want the derivative of the full process.
θ = Flux.params([p1,p2])
gs2 = gradient(θ) do
p2=re(p1)(u0)
criterion2(p2)
end
Oh I missed that. You can’t differentiate that in isolation then. You have to differentiate the full process if you want the derivative of the full process.
θ = Flux.params([p1,p2])
gs2 = gradient(θ) do
p2=re(p1)(u0)
criterion2(p2)
end