[SciPy-dev] Recent changes in scipy.io

Matthew Brett matthew.brett at gmail.com
Thu Oct 18 09:28:55 EDT 2007


Thanks for the report...

On 10/17/07, Nils Wagner <nwagner at iam.uni-stuttgart.de> wrote:
> Hi all,
>
> scipy.test(1) results in (0.7.0.dev3440)
>
> ======================================================================
> ERROR: check loadmat case cell_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case cellnest_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case emptycell_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case object_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case stringarray_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case struct_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case structarr_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case structnest_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 327, in matrix_writer_factory
>      raise TypeError, 'Cannot save object arrays in Mat4'
> TypeError: Cannot save object arrays in Mat4
>
> ======================================================================
> ERROR: check loadmat case unicode_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 92, in cc
>      savemat(mat_stream, expected, format)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio.py",
> line 131, in savemat
>      MW.put_variables(mdict)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 340, in put_variables
>      matrix_writer_factory(self.file_stream, var,
> name).write()
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/mio4.py",
> line 286, in write
>      st = st_arr.item().encode('ascii')
> UnicodeEncodeError: 'ascii' codec can't encode characters
> in position 11-33: ordinal not in range(128)
>
> ======================================================================
> FAIL: check loadmat case 3dmatrix_round_trip
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 94, in cc
>      self._check_case(name, [mat_stream], expected)
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 79, in _check_case
>      self._check_level(k_label, expected, matdict[k])
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/io/tests/test_mio.py",
> line 66, in _check_level
>      assert_array_almost_equal(actual, expected,
> err_msg=label, decimal=5)
>    File
> "/usr/local/lib64/python2.5/site-packages/numpy/testing/utils.py",
> line 232, in assert_array_almost_equal
>      header='Arrays are not almost equal')
>    File
> "/usr/local/lib64/python2.5/site-packages/numpy/testing/utils.py",
> line 201, in assert_array_compare
>      assert cond, msg
> AssertionError:
> Arrays are not almost equal
> test 3dmatrix_round_trip; file <cStringIO.StringO object
> at 0x103e180>, variable test3dmatrix
> (shapes (6, 4), (2, 3, 4) mismatch)
>   x: array([[  1.,   7.,  13.,  19.],
>         [  3.,   9.,  15.,  21.],
>         [  5.,  11.,  17.,  23.],...
>   y: array([[[ 1,  7, 13, 19],
>          [ 3,  9, 15, 21],
>          [ 5, 11, 17, 23]],...
>
> ======================================================================
> FAIL: test_explicit (scipy.tests.test_odr.TestODR)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/odr/tests/test_odr.py",
> line 50, in test_explicit
>      -8.7849712165253724e-02]),
>    File
> "/usr/local/lib64/python2.5/site-packages/numpy/testing/utils.py",
> line 232, in assert_array_almost_equal
>      header='Arrays are not almost equal')
>    File
> "/usr/local/lib64/python2.5/site-packages/numpy/testing/utils.py",
> line 217, in assert_array_compare
>      assert cond, msg
> AssertionError:
> Arrays are not almost equal
>
> (mismatch 100.0%)
>   x: array([  1.26462971e+03,  -5.42545890e+01,
>  -8.64250389e-02])
>   y: array([  1.26465481e+03,  -5.40184100e+01,
>  -8.78497122e-02])
>
> ======================================================================
> FAIL: test_multi (scipy.tests.test_odr.TestODR)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/usr/local/lib64/python2.5/site-packages/scipy/odr/tests/test_odr.py",
> line 191, in test_multi
>      0.5101147161764654,  0.5173902330489161]),
>    File
> "/usr/local/lib64/python2.5/site-packages/numpy/testing/utils.py",
> line 232, in assert_array_almost_equal
>      header='Arrays are not almost equal')
>    File
> "/usr/local/lib64/python2.5/site-packages/numpy/testing/utils.py",
> line 217, in assert_array_compare
>      assert cond, msg
> AssertionError:
> Arrays are not almost equal
>
> (mismatch 100.0%)
>   x: array([ 4.31272063,  2.44289312,  7.76215871,
>  0.55995622,  0.46423343])
>   y: array([ 4.37998803,  2.43330576,  8.00288459,
>  0.51011472,  0.51739023])
>
> Nils
>
>
> ----------------------------------------------------------------------
> Ran 1793 tests in 4.942s
>
> FAILED (failures=3, errors=9)
> <unittest._TextTestResult run=1793 errors=9 failures=3>
>
> _______________________________________________
> Scipy-dev mailing list
> Scipy-dev at scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-dev
>



More information about the SciPy-Dev mailing list