Difference between tf.GradientTape and backprop.GradientTape

Viewed 132

When looking at the OptimizerV2 code in Tensorflow 1.15 I noticed that they use backprop.GradientTape to compute the gradient.

I can't find any online reference to this class, only to tf.GradientTape. What is the difference between the two?

1 Answers

There is no difference, it is the same class:

@tf_export("GradientTape", "autodiff.GradientTape", v1=["GradientTape"])
class GradientTape(object):
  ...

TensorFlow internals generally do not use the public API and import other internal modules directly.

Related