mxnet-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kan Wu (Jira)" <j...@apache.org>
Subject [jira] [Created] (MXNET-1426) Fix the wrong result of sum(inf, inf) and mean(inf, inf)
Date Sun, 22 Sep 2019 03:28:00 GMT
Kan Wu created MXNET-1426:
-----------------------------

             Summary: Fix the wrong result of sum(inf, inf) and mean(inf, inf)
                 Key: MXNET-1426
                 URL: https://issues.apache.org/jira/browse/MXNET-1426
             Project: Apache MXNet
          Issue Type: Bug
          Components: Apache MXNet Backend
            Reporter: Kan Wu


Hi, there.
I fix the wrong result of sum(inf, inf) and mean(inf, inf).

Test Case:
```python
import mxnet as mx
import numpy as np

x = mx.nd.array([np.inf, np.inf])
print(mx.nd.mean(x))
print(mx.nd.sum(x))

x = mx.nd.array([-np.inf, -np.inf])
print(mx.nd.mean(x))
print(mx.nd.sum(x))

x = mx.nd.array([np.inf, -np.inf])
print(mx.nd.mean(x))
print(mx.nd.sum(x))
```
The result should be `inf` rather than `nan`.




--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@mxnet.apache.org
For additional commands, e-mail: issues-help@mxnet.apache.org


Mime
View raw message