From efb0528ee8f946a403394efd75b5ec4a38b7050e Mon Sep 17 00:00:00 2001 From: Anirudh Acharya Date: Tue, 31 Jul 2018 18:22:31 -0700 Subject: [PATCH 1/2] Fix flaky test for kl_loss --- tests/python/unittest/test_loss.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/python/unittest/test_loss.py b/tests/python/unittest/test_loss.py index 8d5b86341a88..0a413be14f32 100644 --- a/tests/python/unittest/test_loss.py +++ b/tests/python/unittest/test_loss.py @@ -127,7 +127,9 @@ def test_logistic_loss_equal_bce(): assert_almost_equal(loss_binary(data, label).asnumpy(), loss_bce(data, label).asnumpy()) assert_almost_equal(loss_signed(data, 2 * label - 1).asnumpy(), loss_bce(data, label).asnumpy()) -@with_seed(1234) +# @anirudhacharya - removing the fixed seed for this test. +# Issue to track - https://github.com/apache/incubator-mxnet/issues/11697 +@with_seed() def test_kl_loss(): N = 20 data = mx.random.uniform(-1, 1, shape=(N, 10)) From 20daf55939eb03d34a2303bcfcc54bac94003ffd Mon Sep 17 00:00:00 2001 From: Anirudh Date: Wed, 8 Aug 2018 17:28:33 -0700 Subject: [PATCH 2/2] remove comment. --- tests/python/unittest/test_loss.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/tests/python/unittest/test_loss.py b/tests/python/unittest/test_loss.py index 0a413be14f32..cb55cda9250f 100644 --- a/tests/python/unittest/test_loss.py +++ b/tests/python/unittest/test_loss.py @@ -127,8 +127,6 @@ def test_logistic_loss_equal_bce(): assert_almost_equal(loss_binary(data, label).asnumpy(), loss_bce(data, label).asnumpy()) assert_almost_equal(loss_signed(data, 2 * label - 1).asnumpy(), loss_bce(data, label).asnumpy()) -# @anirudhacharya - removing the fixed seed for this test. -# Issue to track - https://github.com/apache/incubator-mxnet/issues/11697 @with_seed() def test_kl_loss(): N = 20