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

Possible Fix for test_dem2pts failure #22

Merged
merged 3 commits into from
May 7, 2015

Conversation

stoiver
Copy link
Member

@stoiver stoiver commented May 7, 2015

Duncan has been getting an error when using an environment with numpy 1.9

ERROR: test_dem2pts_bounding_box_v2 (main.Test_Dem2Pts)
Test conversion from dem in ascii format to native NetCDF format

Traceback (most recent call last):
File "test_dem2pts.py", line 92, in test_dem2pts_bounding_box_v2
verbose=False)
File "/nas/mnh/georisk_models/inundation/sandpits/dgray/anuga_core/anuga/file_conversion/dem2pts.py", line 50, in dem2pts
result = apply(_dem2pts, [name_in], kwargs)
File "/nas/mnh/georisk_models/inundation/sandpits/dgray/anuga_core/anuga/file_conversion/dem2pts.py", line 155, in _dem2pts
dem_elevation_r = num.reshape(dem_elevation, (nrows, ncols))
File "/scratch/anaconda/lib/python2.7/site-packages/numpy/core/fromnumeric.py", line 220, in reshape
return _wrapit(a, 'reshape', newshape, order=order)
File "/scratch/anaconda/lib/python2.7/site-packages/numpy/core/fromnumeric.py", line 45, in _wrapit
result = getattr(asarray(obj), method)(_args, *_kwds)
File "/scratch/anaconda/lib/python2.7/site-packages/numpy/core/numeric.py", line 462, in asarray
return array(a, dtype, copy=False, order=order)
IOError: Index exceeds dimension bound

It might have to do with dem_elevation not being a numpy array. So have removed this problem

@coveralls
Copy link

Coverage Status

Coverage increased (+0.0%) to 65.46% when pulling 6dba074 on stoiver:master into fc38d5e on GeoscienceAustralia:master.

stoiver added a commit that referenced this pull request May 7, 2015
Possible Fix for test_dem2pts failure
@stoiver stoiver merged commit 664aea9 into GeoscienceAustralia:master May 7, 2015
stoiver added a commit that referenced this pull request Dec 27, 2019
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 this pull request may close these issues.

None yet

2 participants