Problem when attempting to initialize Ocean for small region
When I attempt to initialize Ocean for small region, I get an error, if the region does not contain any data. For example, running the below script
from datetime import datetime
from kadlu.geospatial.ocean import Ocean
bounds = dict(
south=43.5, north=43.6, west=-59.8, east=-59.7,
start=datetime(2015,1,1), end=datetime(2015,1,2),
top=0, bottom=10000
)
data_sources = dict(load_temp='hycom', load_windspeed='wwiii')
gully = Ocean(**bounds, **data_sources)
results in this error message,
WWIII 2015-01-01 windU: processed and inserted 0 rows. 654921 null values removed, 1360359 duplicates ignored
WWIII 2015-01-01 windV: processed and inserted 0 rows. 654921 null values removed, 1360359 duplicates ignored
Traceback (most recent call last):
File "test_kadlu.py", line 23, in <module>
gully = Ocean(**bounds2, **data_sources)
File "/home/oliskir/src/anaconda3/envs/kadlu_env/lib/python3.7/site-packages/kadlu/geospatial/ocean.py", line 204, in __init__
for i in interpolations: i.start()
File "/home/oliskir/src/anaconda3/envs/kadlu_env/lib/python3.7/site-packages/kadlu/geospatial/ocean.py", line 192, in <genexpr>
columns = (fcn(v=v, data=data, **kwargs) for fcn, v in pipe)
File "/home/oliskir/src/anaconda3/envs/kadlu_env/lib/python3.7/site-packages/kadlu/geospatial/data_sources/wwiii.py", line 235, in load_wind_uv
wind_u, lat, lon, epoch, _, wind_v, _, _, _, _ = np.array(db.fetchall()).T
ValueError: not enough values to unpack (expected 10, got 0)
How should we resolve this?
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information