jwfromm commented on a change in pull request #8105:
URL: https://github.com/apache/tvm/pull/8105#discussion_r640999354



##########
File path: python/tvm/relay/op/transform.py
##########
@@ -1087,6 +1087,10 @@ def gather_nd(data, indices, batch_dims=0):
     batch_dims : int
         The number of batch dimensions.
 
+    num_indices_per_tuple : int
+        The size of an indexing tuple, which is a fixed value and the same as 
indices.shape[0]
+        Only needed when other dimensions of indices are dynamic.

Review comment:
       does the default value of -1 have some significance or does it just mean 
its not used by default?

##########
File path: include/tvm/relay/attrs/transform.h
##########
@@ -146,11 +146,18 @@ struct GatherAttrs : public tvm::AttrsNode<GatherAttrs> {
 
 struct GatherNDAttrs : public tvm::AttrsNode<GatherNDAttrs> {
   Integer batch_dims;
+  Integer num_indices_per_tuple;
 
   TVM_DECLARE_ATTRS(GatherAttrs, "relay.attrs.GatherNDAttrs") {
     TVM_ATTR_FIELD(batch_dims).set_default(Integer(0)).describe("The number of 
batch dimensions.");
+    TVM_ATTR_FIELD(num_indices_per_tuple)

Review comment:
       I think this name is a little difficult to parse, would it make sense to 
instead call it something like `num_dims_per_index` or `index_rank`?




-- 
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