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

Errors with scipy 0.12.0 #493

Closed
ajdawson opened this issue May 5, 2013 · 0 comments · Fixed by #934
Closed

Errors with scipy 0.12.0 #493

ajdawson opened this issue May 5, 2013 · 0 comments · Fixed by #934

Comments

@ajdawson
Copy link
Member

ajdawson commented May 5, 2013

I just upgraded to scipy 0.12.0 on one of my machines and this seemingly causes some errors in the test suite I have not seen previously. There are several errors such as:

======================================================================
ERROR: test_bilinear_larger (iris.tests.test_regrid.TestRegridBilinear)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/tests/test_regrid.py", line 202, in test_bilinear_larger
self.assertCMLApproxData(self.source.regridded(self.larger), ('regrid', 'bilinear_larger.cml'))
  File "<string>", line 2, in regrid
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/analysis/interpolate.py", line 470, in regrid
    new_data = linear(source_cube, points_dict, **kwargs).data
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/analysis/interpolate.py", line 642, in linear
    result = linear(result, [(coord, cells)], extrapolation_mode=extrapolation_mode)
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/analysis/interpolate.py", line 734, in linear
    data = interpolate(data, sample_values, axis=sample_dim, copy=False)
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/analysis/interpolate.py", line 730, in interpolate
    new_fx = interpolator(np.array(new_x, dtype=fx.dtype))
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/analysis/interpolate.py", line 872, in __call__
    result[interpolator_result_index] = r.transpose(axes)
ValueError: array is not broadcastable to correct shape

I have similar errors for: test_bilinear_larger_lon_right, test_bilinear_larger_lon_left, test_bilinear_larger, test_contrived_non_spherical_curl2, test_contrived_non_spherical_curl1.

There are also errors of this type:

======================================================================
ERROR: test_simple_coord_linear_extrapolation     (iris.tests.test_interpolation.TestLinear1dInterpolation)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/tests/test_interpolation.py", line 337, in test_simple_coord_linear_extrapolation
    r = iris.analysis.interpolate.linear(self.simple2d_cube, [('dim1', 1)])
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/analysis/interpolate.py", line 775, in linear
    new_cube.add_aux_coord(new_coord, dims)
  File "/home/dawson/python/dev/iris-ajdawson/lib/iris/cube.py", line 627, in add_aux_coord
    coord.shape[i]))
ValueError: Unequal lengths. Cube dimension 0 => 4; coord 'dim2' dimension 0 => 3.

for test_simple_coord_linear_extrapolation, test_simple_coord_linear_extrapolation_multipoint1, test_simple_coord_linear_extrapolation_multipoint2.

I'm also getting some failed tests for iris.tests.test_interpolation.TestLinearExtrapolator, which I guess are related.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant