Issue title: gather_nd doesnt work for batched slicing,(even for documented examples)
 Issue body: gather_nd function doesn't work for batched slicing
Steps to Reproduce

Run the following code
```python
import tensorflow as tf
cons_indices=tf.constant([[[1]], [[0]]])
batch=tf.constant([['a', 'b'], ['c', 'd']])
gathered=tf.gather_nd(batch,cons_indices)
sess = tf.Session()
result = sess.run(gathered)
print(result)
sess.close()
```


Always gives an error regarding incompatible dimensions.

Either the documentation needs to be updated to indicate proper argument format
 Comments: 
 Comment 0: When I run your program I get:

[[['c' 'd']] [['a' 'b']]]

which I believe is correct.  Could you provide more information on your version and installation, and the exact error message?
 Comment 1: Closing due to lack of response.  We are happy to reopen if more details emerge!
 Comment 2: In TFv1.0 it tf.gather_nd seems to wrok randomly. Checkout [here](http://stackoverflow.com/questions/43007410/tensorflow-unexpected-tf-gather-nd-behaviour-bug) 
{'source': 'GithubIssues', 'repo_name_with_owner': 'tensorflow/tensorflow', 'issue_id': 168592359, 'repo_stars': 184749.0}