You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by jx...@apache.org on 2018/03/04 08:32:45 UTC
[incubator-mxnet] branch master updated: Fix test_cast (#9951)
This is an automated email from the ASF dual-hosted git repository.
jxie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git
The following commit(s) were added to refs/heads/master by this push:
new 94d3c06 Fix test_cast (#9951)
94d3c06 is described below
commit 94d3c06f8511782f405f5dbf4bccf61647a78cf3
Author: Anirudh Subramanian <an...@gmail.com>
AuthorDate: Sun Mar 4 00:32:39 2018 -0800
Fix test_cast (#9951)
---
tests/python/unittest/test_operator.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/python/unittest/test_operator.py b/tests/python/unittest/test_operator.py
index 1a04e8e..1ee14b6 100644
--- a/tests/python/unittest/test_operator.py
+++ b/tests/python/unittest/test_operator.py
@@ -3229,8 +3229,8 @@ def test_cast():
exe.arg_arrays[0][:] = X
exe.forward(is_train=True)
exe.backward(mx.nd.array(X, dtype=dsttype, ctx=default_context()))
- assert_almost_equal(exe.outputs[0].asnumpy(), X.astype(srctype).astype(dsttype), rtol=1e-3)
- assert_almost_equal(exe.grad_arrays[0].asnumpy(), X.astype(dsttype).astype(srctype), rtol=1e-3)
+ assert_almost_equal(exe.outputs[0].asnumpy(), X.astype(srctype).astype(dsttype), rtol=1e-3, atol=1e-5)
+ assert_almost_equal(exe.grad_arrays[0].asnumpy(), X.astype(dsttype).astype(srctype), rtol=1e-3, atol=1e-5)
@with_seed()
--
To stop receiving notification emails like this one, please contact
jxie@apache.org.