Fix typos in gradients_impl.py documentation

This commit is contained in:
Shawn Presser 2019-11-18 18:11:13 -06:00 committed by GitHub
parent ef0b2bb992
commit 0a7f1e3c12
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -109,7 +109,7 @@ def gradients(ys,
```python
a = tf.ones([1, 2])
b = tf.ones([3, 1])
g1 = tf.gradients([b], [a], unnconnected_gradients='none')
g1 = tf.gradients([b], [a], unconnected_gradients='none')
sess.run(g1) # [None]
g2 = tf.gradients([b], [a], unconnected_gradients='zero')
@ -227,7 +227,7 @@ def gradients_v2(ys, # pylint: disable=invalid-name
```python
a = tf.ones([1, 2])
b = tf.ones([3, 1])
g1 = tf.gradients([b], [a], unnconnected_gradients='none')
g1 = tf.gradients([b], [a], unconnected_gradients='none')
sess.run(g1) # [None]
g2 = tf.gradients([b], [a], unconnected_gradients='zero')