-
Notifications
You must be signed in to change notification settings - Fork 23
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
velox slower than raster for extracting points from .adf rasters? #22
Comments
Hi there, This is a tricky one, thanks for posting! The problem seems to arise if the raster data are stored as integers, rather than doubles. If you simply change the storage mode to double precision before extracting, the issue goes away:
I'm not exactly sure why storing the data as integers causes such a slow-down; the way velox handles data types at the moment, the integer matrix should be converted to a double precision matrix by Rcpp once it's passed to C++, but evidently this isn't happening. I'll try to put together a fix for this particular issue later today and push it to GitHub. On a more general note, the way velox currently handles data types is unsatisfactory (integers are cast as doubles), and should probably be addressed more fundamentally in the long term. |
Hello,
I was trying to use velox to extract points from a wildfire raster and noticed that velox was much slower than raster. I've reproduced this issue on both Linux Mint and OS X. Apologies for the long MWE:
As you can see at the bottom, my resolution at the moment is to resave as GeoTiff and reload, at which point velox is once again much faster on OSX and at least comparable to raster on Linux Mint. But I admit I'm a bit confused. Both systems have plenty of memory.
The text was updated successfully, but these errors were encountered: