ANSHUMAN87 commented on a change in pull request #5588:
URL: https://github.com/apache/incubator-tvm/pull/5588#discussion_r424883702



##########
File path: python/tvm/relay/frontend/tensorflow.py
##########
@@ -1378,9 +1378,11 @@ def _gather_nd():
     def _impl(inputs, attr, params, mod):
         indices_dims = len(_infer_shape(inputs[1], mod))
         indices = _op.transpose(inputs[1], axes=[-1] + 
list(range(indices_dims-1)))
+        attr_new = {}
+        attr_new['one_dim_support'] = True

Review comment:
       @kevinthesun : Sorry for late reply! Actually the difficulty here is 
Gather_ND has different behavior in MXNet & Tensorflow. 
   In MXNet it supports only Dim >= 2, but in Tensorflow it supports Dim >= 1.
   So if we just check Input dims, it may not help the Op works in both the 
case.
   That is the reason i added additional attribute to control it.
   But we can do it another way as well, like adding check in MXNet frontend 
minimum 2-dim, and modify check in Op code to support minimum 1-dim.
   
   In that way also we can solve for both. We can discuss on it, which one will 
be better. Please let me know your valuable opinion, Thanks!




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to