Comments (13)
If i skip the test that stalls then 3 other tests fail:
======================================================================
ERROR: test_gauss_multi_mp (pyresample.test.test_kd_tree.Test)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 546, in _query_resample_kdtree
dt = resample_kdtree.data_pts.dtype
AttributeError: 'cKDTree_MP' object has no attribute 'data_pts'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/test/test_kd_tree.py", line 453, in test_gauss_multi_mp
nprocs=2, segments=1)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 179, in resample_gauss
reduce_data=reduce_data, nprocs=nprocs, segments=segments, with_uncert=with_uncert)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 259, in _resample
segments=segments)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 376, in get_neighbour_info
nprocs=nprocs)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 548, in _query_resample_kdtree
dt = resample_kdtree.data.dtype
AttributeError: 'cKDTree_MP' object has no attribute 'data'
======================================================================
ERROR: test_gauss_multi_mp_segments (pyresample.test.test_kd_tree.Test)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 546, in _query_resample_kdtree
dt = resample_kdtree.data_pts.dtype
AttributeError: 'cKDTree_MP' object has no attribute 'data_pts'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/test/test_kd_tree.py", line 483, in test_gauss_multi_mp_segments
nprocs=2, segments=1)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 179, in resample_gauss
reduce_data=reduce_data, nprocs=nprocs, segments=segments, with_uncert=with_uncert)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 259, in _resample
segments=segments)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 376, in get_neighbour_info
nprocs=nprocs)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 548, in _query_resample_kdtree
dt = resample_kdtree.data.dtype
AttributeError: 'cKDTree_MP' object has no attribute 'data'
======================================================================
ERROR: test_nearest_mp (pyresample.test.test_kd_tree.Test)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 546, in _query_resample_kdtree
dt = resample_kdtree.data_pts.dtype
AttributeError: 'cKDTree_MP' object has no attribute 'data_pts'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/test/test_kd_tree.py", line 266, in test_nearest_mp
self.area_def, 50000, nprocs=2, segments=1)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 101, in resample_nearest
reduce_data=reduce_data, nprocs=nprocs, segments=segments)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 259, in _resample
segments=segments)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 376, in get_neighbour_info
nprocs=nprocs)
File "/home/antonio/debian/git/build-area/pyresample-1.1.6/pyresample/kd_tree.py", line 548, in _query_resample_kdtree
dt = resample_kdtree.data.dtype
AttributeError: 'cKDTree_MP' object has no attribute 'data'
----------------------------------------------------------------------
Ran 105 tests in 130.320s
FAILED (errors=3, skipped=1)
from pyresample.
Seems to work on travis ? https://travis-ci.org/pytroll/pyresample/builds/112546653
from pyresample.
If my understanding is correct you install pykdtree while the error reported seems to happen when pykdtree is not installed and scipy is used instead.
P.S.: does pykdtree support python3?
from pyresample.
Sorry, I had missed that
from pyresample.
@avalentino Yes pykdtree runs on python 3.5: https://travis-ci.org/storpipfugl/pykdtree
from pyresample.
@avalentino I fixed the last 3 errors in the pre-master branch, could see if it works for you also ?
I wasn't able to see the stalling though (python 3.3)...
from pyresample.
I wasn't able to see the stalling though (python 3.3)...
In my case it was python3.5
Sorry I'm travelling now so I can't provide more details about the configuration or check you fixes right now
I will do it ASAP
from pyresample.
OK, sorry for the long delay.
I still experiment the issue with test_nearest_resize
on pyresample 1.2.4 (and the current master):
- Ubuntu 16.04 LTS (amd64)
- Python 3.5.2
- no pykdtree installed
- scipy 0.17.0
from pyresample.
@avalentino I saw this too when running on Windows with python 2.7, 3.4, and 3.5. It didn't actually stall necessarily, but it took ~25 minutes to finish test_nearest_resize. Once I fixed some things to get pykdtree to work on Windows it took 5-7 seconds to finish.
When you said it works as expected on python 2.7 is that using pykdtree or not?
from pyresample.
FYI I just tested this on my macbook with python 2.7. I ran python setup.py test -s pyresample.test.test_image.Test.test_nearest_resize
with pykdtree and it took 5.592s. Without pykdtree 23.35 minutes. So the tests seem to require pykdtree to perform reasonably at all.
from pyresample.
@davidh-ssec I can confirm that using pykdtree all works fine
from pyresample.
@avalentino is installing pykdtree a "good enough" solution for you or would you like us to look in to why scipy is so much slower? We could also reduce the size of the test so that it passes in a reasonable amount of time even with scipy?
@mraspaud, thoughts?
from pyresample.
@davidh-ssec it is fine to set pykdtree as mandatory dependency (now it is also available a debian package for python3).
Thanks
from pyresample.
Related Issues (20)
- `get_neighbour_info` slows down significantly when working with large target rasters using many segments HOT 3
- `gradient_search` fails when resampling Himawari data HOT 7
- EWA resampling in 1.27 slows down four times than 1.26.1 HOT 69
- Refactor boundary creation logic
- area definition for a rotated pole coordinate system HOT 24
- Index Error when calling `boundary` with non full disk geos ara HOT 5
- Bug where boundary coordinates wrap around 180 degrees when geostationary AreaDefinition extends beyond 180 degrees HOT 7
- Upgrade to Cython 3.0 and check annotations
- Compatibility with libproj v9.3 HOT 23
- How should this warning be addressed? HOT 2
- Catch or fix pyproj UserWarning when loading an AreaDefinition from a netCDF/CF file HOT 1
- Make a Swath definition subclass for interpolated data HOT 4
- The finding of the optimal radius of influence makes assumption on the ordering of the dimensions in the longitude array HOT 4
- Wrong coordinates returned by `AreaDefintion.get_lonlats` for some projections in out-of-Earth locations HOT 6
- dump DynamicAreaDefinition to YAML
- errors in area definition should not be silently ignored HOT 1
- Resampling GOES mesoscale data to my area gives blank data HOT 10
- Remove Configobj as Dependency Due To Security Vulnerability and No Longer Maintaned HOT 3
- YAML area configuration does not allow to specify the dtype and dtype is ignored in equality comparisons HOT 6
- "resample_nearest" GEO swath to eqc has tiny periodic "glitch" in results
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyresample.