acphile opened a new issue #18137:
URL: https://github.com/apache/incubator-mxnet/issues/18137
### operator between different types
for example
```
import mxnet as mx
mx.npx.set_np()
mx.np.arange(5)
array([0., 1., 2., 3., 4.])
b=mx.np.arange(5)
a=b.astype('int32')
a==b
```
it will raise Error:
```
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/ubuntu/incubator-mxnet/python/mxnet/numpy/multiarray.py", line
991, in __eq__
return equal(self, other)
File "/home/ubuntu/incubator-mxnet/python/mxnet/numpy/multiarray.py", line
8451, in equal
return _mx_nd_np.equal(x1, x2, out)
File "/home/ubuntu/incubator-mxnet/python/mxnet/ndarray/numpy/_op.py",
line 6622, in equal
return _api_internal.equal(x1, x2, out)
File "/home/ubuntu/incubator-mxnet/python/mxnet/_ffi/_ctypes/function.py",
line 115, in __call__
raise get_last_ffi_error()
mxnet.base.MXNetError: MXNetError: Type inconsistent, Provided = float32,
inferred type = int32
```
But numpy supports equal operation between different types
### fail to use mxnet.numpy.prod(a.shape)
```
>>> mx.np.prod(a.shape)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<string>", line 31, in prod
AssertionError: Argument a must have NDArray type, but got (5,)
```
while numpy supports that.
### mxnet.numpy.ndarray.diagonal() is not supported
----------------------------------------------------------------
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]