reminisce commented on a change in pull request #13143: [MXNET-1206] Support
NDArray indexing with None and Ellipsis
URL: https://github.com/apache/incubator-mxnet/pull/13143#discussion_r285365544
##########
File path: tests/python/unittest/test_operator.py
##########
@@ -4388,13 +4388,14 @@ def test_normal_case():
def test_empty_tensor():
shape = (2, 3, 0, 4)
- a = np.array([], dtype=np.int32).reshape(shape)
- b = mx.nd.array(a, ctx=default_context(), dtype=a.dtype)
- reps = (2, 4, 6)
+ with mx.np_compat():
Review comment:
nit: Instead of using the `with` statement, you can decorate this function
with `mx.use_np_compat` to avoid indenting the code. This would introduce less
difference between two code versions.
----------------------------------------------------------------
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]
With regards,
Apache Git Services