Skip to content

Instantly share code, notes, and snippets.

@ogrisel
Last active August 29, 2015 14:16
Show Gist options
  • Save ogrisel/676f7d582600036efa60 to your computer and use it in GitHub Desktop.
Save ogrisel/676f7d582600036efa60 to your computer and use it in GitHub Desktop.
isotonic test failures
(py35)ogrisel@is146148:~/code/scikit-learn$ nosetests /tmp/test_isotonic.py
......FF/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/scipy/interpolate/interpolate.py:466: RuntimeWarning: divide by zero encountered in true_divide
slope = (y_hi - y_lo) / (x_hi - x_lo)[:, None]
/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/scipy/interpolate/interpolate.py:469: RuntimeWarning: invalid value encountered in multiply
y_new = slope*(x_new - x_lo)[:, None] + y_lo
F............./volatile/ogrisel/envs/py35/lib/python3.5/site-packages/scipy/interpolate/interpolate.py:466: RuntimeWarning: invalid value encountered in true_divide
slope = (y_hi - y_lo) / (x_hi - x_lo)[:, None]
F
======================================================================
FAIL: test_isotonic.test_isotonic_regression_ties_min
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 92, in test_isotonic_regression_ties_min
assert_array_equal(ir.fit(x, y).transform(x), ir.fit_transform(x, y))
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 739, in assert_array_equal
verbose=verbose, header='Arrays are not equal')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 665, in assert_array_compare
raise AssertionError(msg)
nose.proxy.AssertionError:
Arrays are not equal
(mismatch 14.285714285714292%)
x: array([ 0., 1., 1., 3., 4., 5., 6.])
y: array([ 0., 1., 2., 3., 4., 5., 6.])
>> raise AssertionError('\nArrays are not equal\n\n(mismatch 14.285714285714292%)\n x: array([ 0., 1., 1., 3., 4., 5., 6.])\n y: array([ 0., 1., 2., 3., 4., 5., 6.])')
======================================================================
FAIL: test_isotonic.test_isotonic_regression_ties_max
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 103, in test_isotonic_regression_ties_max
assert_array_equal(ir.fit(x, y).transform(x), ir.fit_transform(x, y))
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 739, in assert_array_equal
verbose=verbose, header='Arrays are not equal')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 665, in assert_array_compare
raise AssertionError(msg)
nose.proxy.AssertionError:
Arrays are not equal
(mismatch 16.66666666666667%)
x: array([ 1., 2., 3., 4., 5., 5.])
y: array([ 1., 2., 3., 4., 5., 6.])
>> raise AssertionError('\nArrays are not equal\n\n(mismatch 16.66666666666667%)\n x: array([ 1., 2., 3., 4., 5., 5.])\n y: array([ 1., 2., 3., 4., 5., 6.])')
======================================================================
FAIL: Test isotonic regression fit, transform and fit_transform
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 134, in test_isotonic_regression_ties_primary_
assert_array_equal(ir.transform(x), y_true)
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 739, in assert_array_equal
verbose=verbose, header='Arrays are not equal')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 628, in assert_array_compare
chk_same_position(x_isnan, y_isnan, hasval='nan')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 608, in chk_same_position
raise AssertionError(msg)
nose.proxy.AssertionError:
Arrays are not equal
x and y nan location mismatch:
x: array([ nan, nan, nan, 22.375, 22.375, 22.375, 22.375,
22.375, 22.375, 23.5 , 23.5 ])
y: array([ 21. , 22.375, 22.375, 22.375, 22.375, 22.375, 22.375,
22.375, 22.375, 23.5 , 25. ])
>> raise AssertionError('\nArrays are not equal\n\nx and y nan location mismatch:\n x: array([ nan, nan, nan, 22.375, 22.375, 22.375, 22.375,\n 22.375, 22.375, 23.5 , 23.5 ])\n y: array([ 21. , 22.375, 22.375, 22.375, 22.375, 22.375, 22.375,\n 22.375, 22.375, 23.5 , 25. ])')
======================================================================
FAIL: test_isotonic.test_isotonic_duplicate_min_entry
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 309, in test_isotonic_duplicate_min_entry
assert_true(all_predictions_finite)
nose.proxy.AssertionError: False is not true
'False is not true' = self._formatMessage('False is not true', "%s is not true" % safe_repr(False))
>> raise self.failureException('False is not true')
----------------------------------------------------------------------
Ran 23 tests in 0.084s
FAILED (failures=4)
(py35)ogrisel@is146148:~/code/scikit-learn$ nosetests /tmp/test_isotonic.py
......FFF..............
======================================================================
FAIL: test_isotonic.test_isotonic_regression_ties_min
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 92, in test_isotonic_regression_ties_min
assert_array_equal(ir.fit(x, y).transform(x), ir.fit_transform(x, y))
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 739, in assert_array_equal
verbose=verbose, header='Arrays are not equal')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 665, in assert_array_compare
raise AssertionError(msg)
nose.proxy.AssertionError:
Arrays are not equal
(mismatch 28.57142857142857%)
x: array([ 0., 0., 0., 3., 4., 5., 6.])
y: array([ 0., 1., 2., 3., 4., 5., 6.])
>> raise AssertionError('\nArrays are not equal\n\n(mismatch 28.57142857142857%)\n x: array([ 0., 0., 0., 3., 4., 5., 6.])\n y: array([ 0., 1., 2., 3., 4., 5., 6.])')
======================================================================
FAIL: test_isotonic.test_isotonic_regression_ties_max
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 103, in test_isotonic_regression_ties_max
assert_array_equal(ir.fit(x, y).transform(x), ir.fit_transform(x, y))
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 739, in assert_array_equal
verbose=verbose, header='Arrays are not equal')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 665, in assert_array_compare
raise AssertionError(msg)
nose.proxy.AssertionError:
Arrays are not equal
(mismatch 33.33333333333333%)
x: array([ 1., 2., 3., 4., 0., 0.])
y: array([ 1., 2., 3., 4., 5., 6.])
>> raise AssertionError('\nArrays are not equal\n\n(mismatch 33.33333333333333%)\n x: array([ 1., 2., 3., 4., 0., 0.])\n y: array([ 1., 2., 3., 4., 5., 6.])')
======================================================================
FAIL: Test isotonic regression fit, transform and fit_transform
----------------------------------------------------------------------
Traceback (most recent call last):
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/nose/case.py", line 198, in runTest
self.test(*self.arg)
File "/tmp/test_isotonic.py", line 134, in test_isotonic_regression_ties_primary_
assert_array_equal(ir.transform(x), y_true)
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 739, in assert_array_equal
verbose=verbose, header='Arrays are not equal')
File "/volatile/ogrisel/envs/py35/lib/python3.5/site-packages/numpy/testing/utils.py", line 665, in assert_array_compare
raise AssertionError(msg)
nose.proxy.AssertionError:
Arrays are not equal
(mismatch 100.0%)
x: array([ 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.])
y: array([ 21. , 22.375, 22.375, 22.375, 22.375, 22.375, 22.375,
22.375, 22.375, 23.5 , 25. ])
>> raise AssertionError('\nArrays are not equal\n\n(mismatch 100.0%)\n x: array([ 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.])\n y: array([ 21. , 22.375, 22.375, 22.375, 22.375, 22.375, 22.375,\n 22.375, 22.375, 23.5 , 25. ])')
----------------------------------------------------------------------
Ran 23 tests in 0.091s
FAILED (failures=3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment