Is there a natural/easy way in tensorflow to implement a custom loss function that uses the derivatives of the model output with respect to the model input?
I have in