Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TST: precision too high in test_normality #1113

Closed
josef-pkt opened this issue Oct 12, 2013 · 1 comment

Comments

Projects
None yet
1 participant
@josef-pkt
Copy link
Member

commented Oct 12, 2013

test precision too high

this has started to fail recently on Debian testing.
I don't know what changed to trigger this. It didn't fail before and there are no related changes in master, IIRC

http://nipy.bic.berkeley.edu/builders/statsmodels-py2.x-sid-sparc/builds/28/steps/shell_4/logs/stdio

======================================================================
FAIL: statsmodels.stats.tests.test_diagnostic.TestDiagnosticG.test_normality
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/statsmodels-0.6.0-py2.7-linux-sparc64.egg/statsmodels/stats/tests/test_diagnostic.py", line 557, in test_normality
    compare_t_est(lf1, lillifors1, decimal=(15, 14))
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/statsmodels-0.6.0-py2.7-linux-sparc64.egg/statsmodels/stats/tests/test_diagnostic.py", line 32, in compare_t_est
    assert_almost_equal(sp[0], sp_dict['statistic'], decimal=decimal[0])
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/numpy/testing/utils.py", line 468, in assert_almost_equal
    raise AssertionError(msg)
AssertionError: 
Arrays are not almost equal to 15 decimals
 ACTUAL: 0.072339090878659695
 DESIRED: 0.0723390908786589

======================================================================
FAIL: statsmodels.stats.tests.test_diagnostic.TestDiagnosticGPandas.test_normality
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/statsmodels-0.6.0-py2.7-linux-sparc64.egg/statsmodels/stats/tests/test_diagnostic.py", line 557, in test_normality
    compare_t_est(lf1, lillifors1, decimal=(15, 14))
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/statsmodels-0.6.0-py2.7-linux-sparc64.egg/statsmodels/stats/tests/test_diagnostic.py", line 32, in compare_t_est
    assert_almost_equal(sp[0], sp_dict['statistic'], decimal=decimal[0])
  File "/home/buildslave/nd-bb-slave-sparc-sid/statsmodels-py2_x-sid-sparc/build/venv/local/lib/python2.7/site-packages/numpy/testing/utils.py", line 468, in assert_almost_equal
    raise AssertionError(msg)
AssertionError: 
Arrays are not almost equal to 15 decimals
 ACTUAL: 0.072339090878659917
 DESIRED: 0.0723390908786589
@josef-pkt

This comment has been minimized.

Copy link
Member Author

commented Oct 24, 2013

another on some Ubuntu one reported on other issues

======================================================================
FAIL: statsmodels.sandbox.tests.test_pca.test_pca_svd
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/home/skipper/statsmodels/statsmodels-skipper/statsmodels/sandbox/tests/test_pca.py", line 60, in test_pca_svd
    assert_array_almost_equal(msign*evecs_svd, evecs, 14)
  File "/usr/local/lib/python2.7/dist-packages/numpy/testing/utils.py", line 811, in assert_array_almost_equal
    header=('Arrays are not almost equal to %d decimals' % decimal))
  File "/usr/local/lib/python2.7/dist-packages/numpy/testing/utils.py", line 644, in assert_array_compare
    raise AssertionError(msg)
AssertionError: 
Arrays are not almost equal to 14 decimals

(mismatch 6.25%)
 x: array([[-0.65989918,  0.22621849, -0.58828335, -0.40899997],
       [-0.15824945,  0.31894199,  0.71689624, -0.59941046],
       [ 0.34887664,  0.9029405 , -0.17151018,  0.1832152 ],
       [-0.64635538,  0.17832458,  0.33251578,  0.66321815]])
 y: array([[-0.65989918,  0.22621849, -0.58828335, -0.40899997],
       [-0.15824945,  0.31894199,  0.71689624, -0.59941046],
       [ 0.34887664,  0.9029405 , -0.17151018,  0.1832152 ],
       [-0.64635538,  0.17832458,  0.33251578,  0.66321815]])

josef-pkt added a commit to josef-pkt/statsmodels that referenced this issue Oct 27, 2013

josef-pkt added a commit to josef-pkt/statsmodels that referenced this issue Oct 27, 2013

TST lower precision in test_pca_svd closes statsmodels#1113
    (lowering all by one, I cannot check)

josef-pkt added a commit to josef-pkt/statsmodels that referenced this issue Oct 27, 2013

@josef-pkt josef-pkt closed this in c3c20ca Nov 8, 2013

jseabold added a commit that referenced this issue Nov 8, 2013

Merge pull request #1157 from josef-pkt/tst_precision_master
TST: Fix precision in some tests. Closes #1113.

jseabold added a commit that referenced this issue Nov 23, 2013

Backport PR #1157: Tst precision master
some adjustments to test precision.

lower to avoid failures on some machines see #1113

(I also have my initial branch written against maintenance)

PierreBdR pushed a commit to PierreBdR/statsmodels that referenced this issue Sep 2, 2014

PierreBdR pushed a commit to PierreBdR/statsmodels that referenced this issue Sep 2, 2014

TST lower precision in test_pca_svd closes statsmodels#1113
    (lowering all by one, I cannot check)

PierreBdR pushed a commit to PierreBdR/statsmodels that referenced this issue Sep 2, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.