[SciPy-User] scipy 0.9.0.dev6984 test failures

Nils Wagner nwagner@iam.uni-stuttgart...
Sun Dec 5 11:13:21 CST 2010


On Sun, 5 Dec 2010 23:15:47 +0800
  Ralf Gommers <ralf.gommers@googlemail.com> wrote:
> On Fri, Dec 3, 2010 at 4:09 PM, Nils Wagner 
><nwagner@iam.uni-stuttgart.de>wrote:
> 
>>
>> ======================================================================
>> FAIL: line-search Newton conjugate gradient optimization
>> routine
>> ----------------------------------------------------------------------
>> Traceback (most recent call last):
>>   File
>>
>> "/data/home/nwagner/local/lib/python2.5/site-packages/scipy/optimize/tests/test_optimize.py",
>> line 177, in test_ncg
>>     assert_(self.gradcalls == 18, self.gradcalls) # 
>>0.8.0
>>   File
>>
>> "/data/home/nwagner/local/lib/python2.5/site-packages/numpy/testing/utils.py",
>> line 34, in assert_
>>     raise AssertionError(msg)
>> AssertionError: 16
>>
> 
> This number of calls has been changing before 
>apparently, and now has
> differences between platforms or python versions. For 
>0.8.0 it had an issue
> on Windows due to == comparison with floating point 
>numbers.
> 
> Since converging faster is not exactly a bug, can we 
>just change the
> comparison to <= ?
> 
> 
>>
>> ======================================================================
>> FAIL: test_basic (test_signaltools.TestMedFilt)
>> ----------------------------------------------------------------------
>> Traceback (most recent call last):
>>   File
>>
>> "/data/home/nwagner/local/lib/python2.5/site-packages/scipy/signal/tests/test_signaltools.py",
>> line 284, in test_basic
>>     [ 0,  7, 11,  7,  4,  4, 19, 19, 24,  0]])
>>   File
>>
>> "/data/home/nwagner/local/lib/python2.5/site-packages/numpy/testing/utils.py",
>> line 686, in assert_array_equal
>>     verbose=verbose, header='Arrays are not equal')
>>   File
>>
>> "/data/home/nwagner/local/lib/python2.5/site-packages/numpy/testing/utils.py",
>> line 618, in assert_array_compare
>>     raise AssertionError(msg)
>> AssertionError:
>> Arrays are not equal
>>
>> (mismatch 8.0%)
>>  x: array([[  0.,  50.,  50.,  50.,  42.,  15.,  15.,
>>  18.,  27.,   0.],
>>        [  0.,  50.,  50.,  50.,  50.,  42.,  19.,  21.,
>>  29.,   0.],
>>        [ 50.,  50.,  50.,  50.,  50.,  47.,  34.,  34.,
>>  46.,  35.],...
>>  y: array([[ 0, 50, 50, 50, 42, 15, 15, 18, 27,  0],
>>        [ 0, 50, 50, 50, 50, 42, 19, 21, 29,  0],
>>        [50, 50, 50, 50, 50, 47, 34, 34, 46, 35],...
>>
> 
> If you change the assert_array_equal calls in 
>TestMedfilt to
> assert_array_almost_equal does the test pass?
> 
> Ralf
  

Hi Ralf,

Unfortunately, the test didn't pass.

======================================================================
FAIL: test_basic (test_signaltools.TestMedFilt)
----------------------------------------------------------------------
Traceback (most recent call last):
   File 
"/home/nwagner/local/lib64/python2.6/site-packages/scipy/signal/tests/test_signaltools.py", 
line 284, in test_basic
     [ 0,  7, 11,  7,  4,  4, 19, 19, 24,  0]])
   File 
"/home/nwagner/local/lib64/python2.6/site-packages/numpy/testing/utils.py", 
line 774, in assert_array_almost_equal
     header='Arrays are not almost equal')
   File 
"/home/nwagner/local/lib64/python2.6/site-packages/numpy/testing/utils.py", 
line 618, in assert_array_compare
     raise AssertionError(msg)
AssertionError:
Arrays are not almost equal

(mismatch 8.0%)
  x: array([[  0.,  50.,  50.,  50.,  42.,  15.,  15., 
 18.,  27.,   0.],
        [  0.,  50.,  50.,  50.,  50.,  42.,  19.,  21., 
 29.,   0.],
        [ 50.,  50.,  50.,  50.,  50.,  47.,  34.,  34., 
 46.,  35.],...
  y: array([[ 0, 50, 50, 50, 42, 15, 15, 18, 27,  0],
        [ 0, 50, 50, 50, 50, 42, 19, 21, 29,  0],
        [50, 50, 50, 50, 50, 47, 34, 34, 46, 35],...

----------------------------------------------------------------------
Ran 312 tests in 3.010s

FAILED (failures=1)


Nils


More information about the SciPy-User mailing list