pacificclimate / climate-explorer-backend

3 stars 1 forks source link

Speed up watershed-related APIs #214

Closed corviday closed 1 year ago

corviday commented 2 years ago

This PR speeds up the APIs that interact with the VIC data by modifying GeoDataGrid2D, used to represent time-invariant datasets that describe the physical landscape underlaying data (elevation minimum, elevation maximum, elevation mean, flow direction, and area) . GeoDataGrid2D preloads latitude, longitude, and variable data by storing it as a numpy array instead of a netCDF variable.

Resolves pacificclimate/climate-explorer-backend#211

This branch needs more testing before it can be merged.

corviday commented 2 years ago

This branch will need to solve pacificclimate/docker-geospatial-python#12 as well, before testing or deployment, since production-like tests on a PCIC docker server can't be done due to errors accessing files.

corviday commented 2 years ago

This branch will not need to solve https://github.com/pacificclimate/docker-geospatial-python/issues/12 ; that was a docker build issue, not a backend code issue as I originally thought. Next steps for this branch are reuilding its docker image to uptake the changes to python-geospatial, and testing to see if it's fast enough. Then merge and deploy if it is.