What's the difference between Variable and ResourceVariable in Tensorflow
<p>In Tensorflow, <code>Variable</code> is a resource, inherited from <code>ResourceBase</code> and managed by <code>ResourceMgr</code>. But why is there another named <code>ResourceVariable</code>? Both of them can be used for optimizers like <code>gradient_descent</code> (see this <a href="https://github.com/tensorflow/tensorflow/blob/master/tensorflow/python/training/gradient_descent_test.py" rel="nofollow noreferrer">example</a>). What's the difference? I know the former is well documented and most often used. What's the purpose of the latter?</p>