Yes, the code could be simplified that way, but that does not necessarily make improvements in my opinion. The original implementation is equally easy to read and fairly efficient. As for the final assignment, note that `n_dim` is already the dimension of the input tensor minus 1, so I think it is fine.
[ Full content available at: https://github.com/apache/incubator-mxnet/pull/12430 ] This message was relayed via gitbox.apache.org for [email protected]
