title: How do I get the gradient of the loss at a TensorFlow variable?
body: <p>The feature I'm after is to be able to tell what the gradient of a given variable is with respect to my error function given some data.</p>
  
  <p>One way to do this would be to see how much the variable has changed after a call to train, but obviously that can vary massively based on the learning algorithm (for example it would be almost impossible to tell with something like RProp) and just isn't very clean.</p>
  
  <p>Thanks in advance.</p>