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

Atlite errors with ESRI:540060 reprojections and Fiji #301

Open
davide-f opened this issue Jun 8, 2023 · 7 comments
Open

Atlite errors with ESRI:540060 reprojections and Fiji #301

davide-f opened this issue Jun 8, 2023 · 7 comments

Comments

@davide-f
Copy link
Contributor

davide-f commented Jun 8, 2023

Description

When using Atlite on regions across borders of [+-180 lon /+-90° lan] GDAL returns error rasterio._err.CPLE_NotSupportedError: Cannot find coordinate operations from 'ESRI:54009' to 'EPSG:4326'.

The error is reproducible executing the PyPSA-Earth workflow on "FJ".

Error Message

Had to go 1 folder(s) up.
INFO:__main__:correction_factor is set as 0.8855
INFO:__main__:Calculate landuse availabilities...
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 2479,5616,2479,1873, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 2479,5616,2479,1873, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 0,6332,2730,3166, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 0,9498,2730,3167, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 2730,11081,2730,1584, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 0,6332,2730,3166, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 0,9498,2730,3167, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=1, msg='Too many points (529 out of 529) failed to transform, unable to compute output bounds.'
WARNING:rasterio._env:CPLE_AppDefined in Unable to compute source region for output window 2730,11081,2730,1584, skipping.
INFO:rasterio._env:GDAL signalled an error: err_no=6, msg="Cannot find coordinate operations from `ESRI:54009' to `EPSG:4326'"
multiprocessing.pool.RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/multiprocessing/pool.py", line 125, in worker
    result = (True, func(*args, **kwds))
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/multiprocessing/pool.py", line 48, in mapstar
    return list(map(*args))
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/site-packages/atlite/gis.py", line 673, in _process_func
    return shape_availability_reprojected(shapes.loc[[i]], *args)[0]
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/site-packages/atlite/gis.py", line 377, in shape_availability_reprojected
    return rio.warp.reproject(
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/site-packages/rasterio/env.py", line 401, in wrapper
    return f(*args, **kwds)
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/site-packages/rasterio/warp.py", line 344, in reproject
    _reproject(
  File "rasterio/_warp.pyx", line 517, in rasterio._warp._reproject
  File "rasterio/_warp.pyx", line 489, in rasterio._warp._reproject
  File "rasterio/_err.pyx", line 221, in rasterio._err.exc_wrap_pointer
rasterio._err.CPLE_NotSupportedError: Cannot find coordinate operations from 'ESRI:54009' to 'EPSG:4326'
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/data/davidef/git_world/pypsa-earth/scripts/build_renewable_profiles.py", line 699, in <module>
    availability = cutout.availabilitymatrix(regions, excluder, **kwargs)
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/site-packages/atlite/gis.py", line 748, in compute_availabilitymatrix
    availability = list(pool.map(_process_func, shapes.index))
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/multiprocessing/pool.py", line 364, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/home/davidef/miniconda3/envs/pypsa-earth/lib/python3.8/multiprocessing/pool.py", line 771, in get
    raise self._value
rasterio._err.CPLE_NotSupportedError: Cannot find coordinate operations from 'ESRI:54009' to 'EPSG:4326'

Your Environment

  • The atlite version used:
  • How you installed atlite (conda, pip or github):
  • Operating System:
  • My environment:
    (output of `conda list`) ``` # Name Version Build Channel

_libgcc_mutex 0.1 conda_forge conda-forge
_openmp_mutex 4.5 2_gnu conda-forge
affine 2.4.0 pyhd8ed1ab_0 conda-forge
alsa-lib 1.2.8 h166bdaf_0 conda-forge
amply 0.1.5 pyhd8ed1ab_0 conda-forge
anyio 3.7.0 pyhd8ed1ab_1 conda-forge
appdirs 1.4.4 pyh9f0ad1d_0 conda-forge
argon2-cffi 21.3.0 pyhd8ed1ab_0 conda-forge
argon2-cffi-bindings 21.2.0 py38h0a891b7_3 conda-forge
asttokens 2.2.1 pyhd8ed1ab_0 conda-forge
async-lru 2.0.2 pyhd8ed1ab_0 conda-forge
atk-1.0 2.38.0 hd4edc92_1 conda-forge
atlite 0.2.11 pyhd8ed1ab_0 conda-forge
attr 2.5.1 h166bdaf_1 conda-forge
attrs 23.1.0 pyh71513ae_1 conda-forge
aws-c-auth 0.6.27 he072965_1 conda-forge
aws-c-cal 0.5.26 hf677bf3_1 conda-forge
aws-c-common 0.8.19 hd590300_0 conda-forge
aws-c-compression 0.2.16 hbad4bc6_7 conda-forge
aws-c-event-stream 0.2.20 hb4b372c_7 conda-forge
aws-c-http 0.7.7 h2632f9a_4 conda-forge
aws-c-io 0.13.21 h9fef7b8_5 conda-forge
aws-c-mqtt 0.8.11 h2282364_1 conda-forge
aws-c-s3 0.3.0 hcb5a9b2_2 conda-forge
aws-c-sdkutils 0.1.9 hbad4bc6_2 conda-forge
aws-checksums 0.1.14 hbad4bc6_7 conda-forge
aws-crt-cpp 0.20.2 he0fdcb3_0 conda-forge
aws-sdk-cpp 1.10.57 h059227d_13 conda-forge
babel 2.12.1 pyhd8ed1ab_1 conda-forge
backcall 0.2.0 pyh9f0ad1d_0 conda-forge
backports 1.0 pyhd8ed1ab_3 conda-forge
backports.functools_lru_cache 1.6.4 pyhd8ed1ab_0 conda-forge
beautifulsoup4 4.12.2 pyha770c72_0 conda-forge
bleach 6.0.0 pyhd8ed1ab_0 conda-forge
blosc 1.21.4 h0f2a231_0 conda-forge
bokeh 3.1.1 pyhd8ed1ab_0 conda-forge
boltons 23.0.0 pyhd8ed1ab_0 conda-forge
boost-cpp 1.78.0 h6582d0a_3 conda-forge
bottleneck 1.3.7 py38h7e4f40d_0 conda-forge
branca 0.6.0 pyhd8ed1ab_0 conda-forge
brotli 1.0.9 h166bdaf_8 conda-forge
brotli-bin 1.0.9 h166bdaf_8 conda-forge
bzip2 1.0.8 h7f98852_4 conda-forge
c-ares 1.19.1 hd590300_0 conda-forge
c-blosc2 2.9.2 hb4ffafa_0 conda-forge
ca-certificates 2023.5.7 hbcca054_0 conda-forge
cairo 1.16.0 h35add3b_1015 conda-forge
cartopy 0.21.1 py38h1abf878_1 conda-forge
cdsapi 0.6.1 pyhd8ed1ab_0 conda-forge
certifi 2023.5.7 pyhd8ed1ab_0 conda-forge
cffi 1.15.1 py38h4a40e3a_3 conda-forge
cfgv 3.3.1 pyhd8ed1ab_0 conda-forge
cfitsio 4.2.0 hd9d235c_0 conda-forge
cftime 1.6.2 py38h26c90d9_1 conda-forge
chaospy 4.3.13 pypi_0 pypi
charset-normalizer 3.1.0 pyhd8ed1ab_0 conda-forge
click 8.1.3 unix_pyhd8ed1ab_2 conda-forge
click-plugins 1.1.1 py_0 conda-forge
cligj 0.7.2 pyhd8ed1ab_1 conda-forge
cloudpickle 2.2.1 pyhd8ed1ab_0 conda-forge
coin-or-cbc 2.10.10 h9002f0b_0 conda-forge
coin-or-cgl 0.60.7 h516709c_0 conda-forge
coin-or-clp 1.17.8 h1ee7a9c_0 conda-forge
coin-or-osi 0.108.8 ha2443b9_0 conda-forge
coin-or-utils 2.11.9 hee58242_0 conda-forge
coincbc 2.10.10 0_metapackage conda-forge
colorama 0.4.6 pyhd8ed1ab_0 conda-forge
colorcet 3.0.1 pyhd8ed1ab_0 conda-forge
comm 0.1.3 pyhd8ed1ab_0 conda-forge
conda 23.3.1 py38h578d9bd_0 conda-forge
conda-package-handling 2.0.2 pyh38be061_0 conda-forge
conda-package-streaming 0.8.0 pyhd8ed1ab_0 conda-forge
configargparse 1.5.3 pyhd8ed1ab_0 conda-forge
connection_pool 0.0.3 pyhd3deb0d_0 conda-forge
contextily 1.3.0 pyhd8ed1ab_0 conda-forge
contourpy 1.0.7 py38hfbd4bf9_0 conda-forge
country_converter 1.0.0 pyhd8ed1ab_1 conda-forge
countrycode 0.2 pypi_0 pypi
cryptography 41.0.1 py38hcdda232_0 conda-forge
curl 8.1.2 h409715c_0 conda-forge
cycler 0.11.0 pyhd8ed1ab_0 conda-forge
cytoolz 0.12.0 py38h0a891b7_1 conda-forge
dask 2023.5.0 pyhd8ed1ab_0 conda-forge
dask-core 2023.5.0 pyhd8ed1ab_0 conda-forge
datashader 0.15.0 pyhd8ed1ab_0 conda-forge
datashape 0.5.4 py_1 conda-forge
datrie 0.8.2 py38h0a891b7_6 conda-forge
dbus 1.13.6 h5008d03_3 conda-forge
debugpy 1.6.7 py38h8dc9893_0 conda-forge
decorator 5.1.1 pyhd8ed1ab_0 conda-forge
defusedxml 0.7.1 pyhd8ed1ab_0 conda-forge
deprecation 2.1.0 pyh9f0ad1d_0 conda-forge
descartes 1.1.0 py_4 conda-forge
distlib 0.3.6 pyhd8ed1ab_0 conda-forge
distributed 2023.5.0 pyhd8ed1ab_0 conda-forge
docutils 0.20.1 py38h578d9bd_0 conda-forge
dpath 2.1.6 pyha770c72_0 conda-forge
earth-osm 0.1.0 pyhd8ed1ab_0 conda-forge
entrypoints 0.4 pyhd8ed1ab_0 conda-forge
entsoe-py 0.5.8 pyhd8ed1ab_0 conda-forge
et_xmlfile 1.1.0 pyhd8ed1ab_0 conda-forge
exceptiongroup 1.1.1 pyhd8ed1ab_0 conda-forge
executing 1.2.0 pyhd8ed1ab_0 conda-forge
expat 2.5.0 hcb278e6_1 conda-forge
filelock 3.12.0 pyhd8ed1ab_0 conda-forge
fiona 1.9.4 py38h887bb71_0 conda-forge
flit-core 3.9.0 pyhd8ed1ab_0 conda-forge
fmt 9.1.0 h924138e_0 conda-forge
folium 0.14.0 pyhd8ed1ab_0 conda-forge
font-ttf-dejavu-sans-mono 2.37 hab24e00_0 conda-forge
font-ttf-inconsolata 3.000 h77eed37_0 conda-forge
font-ttf-source-code-pro 2.038 h77eed37_0 conda-forge
font-ttf-ubuntu 0.83 hab24e00_0 conda-forge
fontconfig 2.14.2 h14ed4e7_0 conda-forge
fonts-conda-ecosystem 1 0 conda-forge
fonts-conda-forge 1 0 conda-forge
fonttools 4.39.4 py38h01eb140_0 conda-forge
freetype 2.12.1 hca18f0e_1 conda-forge
freexl 1.0.6 h166bdaf_1 conda-forge
fribidi 1.0.10 h36c2ea0_0 conda-forge
fsspec 2023.5.0 pyh1a96a4e_0 conda-forge
future 0.18.3 pyhd8ed1ab_0 conda-forge
gdal 3.7.0 py38h9e9f257_0 conda-forge
gdk-pixbuf 2.42.10 h6b639ba_2 conda-forge
geographiclib 1.52 pyhd8ed1ab_0 conda-forge
geojson-rewind 1.0.2 pyhd8ed1ab_0 conda-forge
geopandas 0.13.1 pyhd8ed1ab_0 conda-forge
geopandas-base 0.13.1 pyha770c72_0 conda-forge
geopy 2.3.0 pyhd8ed1ab_0 conda-forge
geos 3.11.2 hcb278e6_0 conda-forge
geotiff 1.7.1 h480ec47_8 conda-forge
geoviews 1.10.0 pyhd8ed1ab_0 conda-forge
geoviews-core 1.10.0 pyha770c72_0 conda-forge
gettext 0.21.1 h27087fc_0 conda-forge
gflags 2.2.2 he1b5a44_1004 conda-forge
giflib 5.2.1 h0b41bf4_3 conda-forge
gitdb 4.0.10 pyhd8ed1ab_0 conda-forge
gitpython 3.1.31 pyhd8ed1ab_0 conda-forge
glib 2.76.3 hfc55251_0 conda-forge
glib-tools 2.76.3 hfc55251_0 conda-forge
glog 0.6.0 h6f12383_0 conda-forge
glpk 5.0 h445213a_0 conda-forge
gmp 6.2.1 h58526e2_0 conda-forge
googledrivedownloader 0.4 pypi_0 pypi
graphite2 1.3.13 h58526e2_1001 conda-forge
graphviz 8.0.5 h28d9a01_0 conda-forge
gst-plugins-base 1.22.0 h4243ec0_2 conda-forge
gstreamer 1.22.0 h25f0c4b_2 conda-forge
gtk2 2.24.33 h90689f9_2 conda-forge
gts 0.7.6 h64030ff_2 conda-forge
gurobi 9.5.0 py38_0 gurobi
harfbuzz 7.3.0 hdb3a94d_0 conda-forge
hdf4 4.2.15 h501b40f_6 conda-forge
hdf5 1.14.0 nompi_hb72d44e_103 conda-forge
highspy 1.5.3 pypi_0 pypi
holoviews 1.16.1 pyhd8ed1ab_0 conda-forge
humanfriendly 10.0 py38h578d9bd_4 conda-forge
hvplot 0.8.3 pyhd8ed1ab_0 conda-forge
icu 72.1 hcb278e6_0 conda-forge
identify 2.5.24 pyhd8ed1ab_0 conda-forge
idna 3.4 pyhd8ed1ab_0 conda-forge
importlib-metadata 6.6.0 pyha770c72_0 conda-forge
importlib_metadata 6.6.0 hd8ed1ab_0 conda-forge
importlib_resources 5.12.0 pyhd8ed1ab_0 conda-forge
iniconfig 2.0.0 pyhd8ed1ab_0 conda-forge
ipopt 3.13.2 h7839693_1 conda-forge
ipykernel 6.23.1 pyh210e3f2_0 conda-forge
ipython 8.12.2 pyh41d4057_0 conda-forge
jedi 0.18.2 pyhd8ed1ab_0 conda-forge
jinja2 3.1.2 pyhd8ed1ab_1 conda-forge
joblib 1.2.0 pyhd8ed1ab_0 conda-forge
json-c 0.16 hc379101_0 conda-forge
json5 0.9.5 pyh9f0ad1d_0 conda-forge
jsonpatch 1.32 pyhd8ed1ab_0 conda-forge
jsonpointer 2.0 py_0 conda-forge
jsonschema 4.17.3 pyhd8ed1ab_0 conda-forge
jupyter-lsp 2.2.0 pyhd8ed1ab_0 conda-forge
jupyter_client 8.2.0 pyhd8ed1ab_0 conda-forge
jupyter_core 5.3.0 py38h578d9bd_0 conda-forge
jupyter_events 0.6.3 pyhd8ed1ab_0 conda-forge
jupyter_server 2.6.0 pyhd8ed1ab_0 conda-forge
jupyter_server_terminals 0.4.4 pyhd8ed1ab_1 conda-forge
jupyterlab 4.0.1 pyhd8ed1ab_0 conda-forge
jupyterlab_pygments 0.2.2 pyhd8ed1ab_0 conda-forge
jupyterlab_server 2.22.1 pyhd8ed1ab_0 conda-forge
kealib 1.5.1 h3845be2_3 conda-forge
keyutils 1.6.1 h166bdaf_0 conda-forge
kiwisolver 1.4.4 py38h43d8883_1 conda-forge
krb5 1.20.1 h81ceb04_0 conda-forge
lame 3.100 h166bdaf_1003 conda-forge
lcms2 2.15 haa2dc70_1 conda-forge
ld_impl_linux-64 2.40 h41732ed_0 conda-forge
lerc 4.0.0 h27087fc_0 conda-forge
libabseil 20230125.2 cxx17_h59595ed_2 conda-forge
libaec 1.0.6 hcb278e6_1 conda-forge
libarchive 3.6.2 h3d51595_0 conda-forge
libarrow 12.0.0 hed73b3e_6_cpu conda-forge
libblas 3.9.0 17_linux64_openblas conda-forge
libbrotlicommon 1.0.9 h166bdaf_8 conda-forge
libbrotlidec 1.0.9 h166bdaf_8 conda-forge
libbrotlienc 1.0.9 h166bdaf_8 conda-forge
libcap 2.67 he9d0100_0 conda-forge
libcblas 3.9.0 17_linux64_openblas conda-forge
libclang 16.0.3 default_h1cdf331_2 conda-forge
libclang13 16.0.3 default_h4d60ac6_2 conda-forge
libcrc32c 1.1.2 h9c3ff4c_0 conda-forge
libcups 2.3.3 h36d4200_3 conda-forge
libcurl 8.1.2 h409715c_0 conda-forge
libdeflate 1.18 h0b41bf4_0 conda-forge
libedit 3.1.20191231 he28a2e2_2 conda-forge
libev 4.33 h516909a_1 conda-forge
libevent 2.1.12 hf998b51_1 conda-forge
libexpat 2.5.0 hcb278e6_1 conda-forge
libffi 3.4.2 h7f98852_5 conda-forge
libflac 1.4.2 h27087fc_0 conda-forge
libgcc-ng 13.1.0 he5830b7_0 conda-forge
libgcrypt 1.10.1 h166bdaf_0 conda-forge
libgd 2.3.3 hfa28ad5_6 conda-forge
libgdal 3.7.0 he76be6c_0 conda-forge
libgfortran-ng 13.1.0 h69a702a_0 conda-forge
libgfortran5 13.1.0 h15d22d2_0 conda-forge
libglib 2.76.3 hebfc3b9_0 conda-forge
libgomp 13.1.0 he5830b7_0 conda-forge
libgoogle-cloud 2.11.0 hac9eb74_0 conda-forge
libgpg-error 1.46 h620e276_0 conda-forge
libgrpc 1.54.2 hb20ce57_2 conda-forge
libiconv 1.17 h166bdaf_0 conda-forge
libjpeg-turbo 2.1.5.1 h0b41bf4_0 conda-forge
libkml 1.3.0 h37653c0_1015 conda-forge
liblapack 3.9.0 17_linux64_openblas conda-forge
liblapacke 3.9.0 17_linux64_openblas conda-forge
libllvm14 14.0.6 hcd5def8_3 conda-forge
libllvm16 16.0.3 hbf9e925_1 conda-forge
libmamba 1.4.2 hcea66bb_0 conda-forge
libmambapy 1.4.2 py38h7fa060d_0 conda-forge
libnetcdf 4.9.2 nompi_hdf9a29f_104 conda-forge
libnghttp2 1.52.0 h61bc06f_0 conda-forge
libnsl 2.0.0 h7f98852_0 conda-forge
libnuma 2.0.16 h0b41bf4_1 conda-forge
libogg 1.3.4 h7f98852_1 conda-forge
libopenblas 0.3.23 pthreads_h80387f5_0 conda-forge
libopus 1.3.1 h7f98852_1 conda-forge
libpng 1.6.39 h753d276_0 conda-forge
libpq 15.3 hbcd7760_0 conda-forge
libprotobuf 3.21.12 h3eb15da_0 conda-forge
librsvg 2.56.0 h5cef280_0 conda-forge
librttopo 1.1.0 h0d5128d_13 conda-forge
libsndfile 1.2.0 hb75c966_0 conda-forge
libsodium 1.0.18 h36c2ea0_1 conda-forge
libsolv 0.7.23 h3eb15da_0 conda-forge
libspatialindex 1.9.3 h9c3ff4c_4 conda-forge
libspatialite 5.0.1 h7d1ca68_25 conda-forge
libsqlite 3.42.0 h2797004_0 conda-forge
libssh2 1.11.0 h0841786_0 conda-forge
libstdcxx-ng 13.1.0 hfd8a6a1_0 conda-forge
libsystemd0 253 h8c4010b_1 conda-forge
libthrift 0.18.1 h8fd135c_2 conda-forge
libtiff 4.5.0 ha587672_6 conda-forge
libtool 2.4.7 h27087fc_0 conda-forge
libutf8proc 2.8.0 h166bdaf_0 conda-forge
libuuid 2.38.1 h0b41bf4_0 conda-forge
libvorbis 1.3.7 h9c3ff4c_0 conda-forge
libwebp 1.3.0 hb47c5f0_0 conda-forge
libwebp-base 1.3.0 h0b41bf4_0 conda-forge
libxcb 1.13 h7f98852_1004 conda-forge
libxkbcommon 1.5.0 h79f4944_1 conda-forge
libxml2 2.10.4 hfdac1af_0 conda-forge
libxslt 1.1.37 h873f0b0_0 conda-forge
libzip 1.9.2 hc929e4a_1 conda-forge
libzlib 1.2.13 h166bdaf_4 conda-forge
linkify-it-py 2.0.0 pyhd8ed1ab_0 conda-forge
linopy 0.1.5 pypi_0 pypi
llvmlite 0.40.0 py38h94a1851_0 conda-forge
locket 1.0.0 pyhd8ed1ab_0 conda-forge
lxml 4.9.2 py38h215a2d7_0 conda-forge
lz4 4.3.2 py38hd012fdc_0 conda-forge
lz4-c 1.9.4 hcb278e6_0 conda-forge
lzo 2.10 h516909a_1000 conda-forge
mamba 1.4.2 py38haad2881_0 conda-forge
mapclassify 2.5.0 pyhd8ed1ab_1 conda-forge
markdown 3.4.3 pyhd8ed1ab_0 conda-forge
markdown-it-py 2.2.0 pyhd8ed1ab_0 conda-forge
markupsafe 2.1.3 py38h01eb140_0 conda-forge
matplotlib 3.5.2 py38h578d9bd_1 conda-forge
matplotlib-base 3.5.2 py38h826bfd8_1 conda-forge
matplotlib-inline 0.1.6 pyhd8ed1ab_0 conda-forge
mdit-py-plugins 0.3.5 pyhd8ed1ab_0 conda-forge
mdurl 0.1.0 pyhd8ed1ab_0 conda-forge
memory_profiler 0.61.0 pyhd8ed1ab_0 conda-forge
mercantile 1.2.1 pyhd8ed1ab_0 conda-forge
metis 5.1.0 h58526e2_1006 conda-forge
mistune 2.0.5 pyhd8ed1ab_0 conda-forge
mpg123 1.31.3 hcb278e6_0 conda-forge
msgpack-python 1.0.5 py38hfbd4bf9_0 conda-forge
multipledispatch 0.6.0 py_0 conda-forge
munch 3.0.0 pyhd8ed1ab_0 conda-forge
munkres 1.1.4 pyh9f0ad1d_0 conda-forge
mysql-common 8.0.32 hf1915f5_2 conda-forge
mysql-libs 8.0.32 hca2cd23_2 conda-forge
nbclient 0.8.0 pyhd8ed1ab_0 conda-forge
nbconvert-core 7.4.0 pyhd8ed1ab_0 conda-forge
nbformat 5.9.0 pyhd8ed1ab_0 conda-forge
ncurses 6.3 h27087fc_1 conda-forge
nest-asyncio 1.5.6 pyhd8ed1ab_0 conda-forge
netcdf4 1.6.3 nompi_py38hd31e641_102 conda-forge
networkx 3.1 pyhd8ed1ab_0 conda-forge
nodeenv 1.8.0 pyhd8ed1ab_0 conda-forge
nomkl 1.0 h5ca1d4c_0 conda-forge
notebook-shim 0.2.3 pyhd8ed1ab_0 conda-forge
nspr 4.35 h27087fc_0 conda-forge
nss 3.89 he45b914_0 conda-forge
numba 0.57.0 py38hd559b08_1 conda-forge
numexpr 2.8.4 py38h69a160b_100 conda-forge
numpoly 1.2.8 pypi_0 pypi
numpy 1.24.3 py38h59b608b_0 conda-forge
openjpeg 2.5.0 hfec8fc6_2 conda-forge
openpyxl 3.1.2 py38h01eb140_0 conda-forge
openssl 3.1.1 hd590300_1 conda-forge
orc 1.8.3 h2f23424_1 conda-forge
overrides 7.3.1 pyhd8ed1ab_0 conda-forge
packaging 23.1 pyhd8ed1ab_0 conda-forge
pandas 1.5.3 py38hdc8b05c_1 conda-forge
pandocfilters 1.5.0 pyhd8ed1ab_0 conda-forge
panel 1.0.4 pyhd8ed1ab_0 conda-forge
pango 1.50.14 heaa33ce_1 conda-forge
param 1.13.0 pyh1a96a4e_0 conda-forge
parso 0.8.3 pyhd8ed1ab_0 conda-forge
partd 1.4.0 pyhd8ed1ab_0 conda-forge
patsy 0.5.3 pyhd8ed1ab_0 conda-forge
pcre2 10.40 hc3806b6_0 conda-forge
pexpect 4.8.0 pyh1a96a4e_2 conda-forge
pickleshare 0.7.5 py_1003 conda-forge
pillow 9.5.0 py38h961100d_0 conda-forge
pip 23.1.2 pyhd8ed1ab_0 conda-forge
pixman 0.40.0 h36c2ea0_0 conda-forge
pkgutil-resolve-name 1.3.10 pyhd8ed1ab_0 conda-forge
plac 1.3.5 pyhd8ed1ab_0 conda-forge
platformdirs 3.5.1 pyhd8ed1ab_0 conda-forge
pluggy 1.0.0 pyhd8ed1ab_5 conda-forge
ply 3.11 py_1 conda-forge
pooch 1.7.0 pyha770c72_3 conda-forge
poppler 23.05.0 hd18248d_1 conda-forge
poppler-data 0.4.12 hd8ed1ab_0 conda-forge
postgresql 15.3 h814edd5_0 conda-forge
powerplantmatching 0.5.7 pyhd8ed1ab_0 conda-forge
pre-commit 3.3.2 pyha770c72_0 conda-forge
progressbar2 4.2.0 pyhd8ed1ab_0 conda-forge
proj 9.2.0 h8ffa02c_0 conda-forge
prometheus_client 0.17.0 pyhd8ed1ab_0 conda-forge
prompt-toolkit 3.0.38 pyha770c72_0 conda-forge
prompt_toolkit 3.0.38 hd8ed1ab_0 conda-forge
protobuf 4.21.12 py38h8dc9893_0 conda-forge
psutil 5.9.5 py38h1de0b5d_0 conda-forge
pthread-stubs 0.4 h36c2ea0_1001 conda-forge
ptyprocess 0.7.0 pyhd3deb0d_0 conda-forge
pulp 2.7.0 py38h578d9bd_0 conda-forge
pulseaudio-client 16.1 hb77b528_4 conda-forge
pure_eval 0.2.2 pyhd8ed1ab_0 conda-forge
py-cpuinfo 9.0.0 pyhd8ed1ab_0 conda-forge
pyarrow 12.0.0 py38hf37be71_6_cpu conda-forge
pybind11-abi 4 hd8ed1ab_3 conda-forge
pycosat 0.6.4 py38h0a891b7_1 conda-forge
pycountry 22.3.5 pyhd8ed1ab_0 conda-forge
pycparser 2.21 pyhd8ed1ab_0 conda-forge
pyct 0.4.6 py_0 conda-forge
pyct-core 0.4.6 py_0 conda-forge
pydoe2 1.3.0 py_0 conda-forge
pygments 2.15.1 pyhd8ed1ab_0 conda-forge
pyomo 6.6.1 py38h17151c0_0 conda-forge
pyopenssl 23.2.0 pyhd8ed1ab_1 conda-forge
pyparsing 3.0.9 pyhd8ed1ab_0 conda-forge
pyproj 3.5.0 py38h2f62729_1 conda-forge
pypsa 0.23.0 pypi_0 pypi
pyqt 5.15.7 py38ha0d8c90_3 conda-forge
pyqt5-sip 12.11.0 py38h8dc9893_3 conda-forge
pyrsistent 0.19.3 py38h1de0b5d_0 conda-forge
pyshp 2.3.1 pyhd8ed1ab_0 conda-forge
pysocks 1.7.1 pyha2e5f31_6 conda-forge
pytables 3.8.0 py38hf59a973_1 conda-forge
pytest 7.3.1 pyhd8ed1ab_0 conda-forge
python 3.8.16 he550d4f_1_cpython conda-forge
python-dateutil 2.8.2 pyhd8ed1ab_0 conda-forge
python-fastjsonschema 2.17.1 pyhd8ed1ab_0 conda-forge
python-json-logger 2.0.7 pyhd8ed1ab_0 conda-forge
python-utils 3.6.0 pyhd8ed1ab_0 conda-forge
python_abi 3.8 3_cp38 conda-forge
pytz 2023.3 pyhd8ed1ab_0 conda-forge
pyviz_comms 2.3.0 pyhd8ed1ab_0 conda-forge
pyyaml 6.0 py38h0a891b7_5 conda-forge
pyzmq 25.1.0 py38h509eb50_0 conda-forge
qt-main 5.15.8 haa3a1c2_11 conda-forge
rasterio 1.3.7 py38ha10f3b6_1 conda-forge
rdma-core 28.9 h59595ed_1 conda-forge
re2 2023.03.02 h8c504da_0 conda-forge
readline 8.2 h8228510_1 conda-forge
reproc 14.2.4 h0b41bf4_0 conda-forge
reproc-cpp 14.2.4 hcb278e6_0 conda-forge
requests 2.31.0 pyhd8ed1ab_0 conda-forge
reretry 0.11.8 pyhd8ed1ab_0 conda-forge
reverse-geocode 1.4.1 pyhd8ed1ab_0 conda-forge
rfc3339-validator 0.1.4 pyhd8ed1ab_0 conda-forge
rfc3986-validator 0.1.1 pyh9f0ad1d_0 conda-forge
rioxarray 0.13.4 pyhd8ed1ab_0 conda-forge
rtree 1.0.1 py38h02d302b_1 conda-forge
ruamel.yaml 0.17.26 py38h01eb140_0 conda-forge
ruamel.yaml.clib 0.2.7 py38h1de0b5d_1 conda-forge
s2n 1.3.44 h06160fa_0 conda-forge
scikit-learn 1.2.2 py38hc099248_2 conda-forge
scipy 1.10.1 py38h59b608b_3 conda-forge
seaborn 0.12.2 hd8ed1ab_0 conda-forge
seaborn-base 0.12.2 pyhd8ed1ab_0 conda-forge
send2trash 1.8.2 pyh41d4057_0 conda-forge
setuptools 67.7.2 pyhd8ed1ab_0 conda-forge
shapely 2.0.1 py38haaa171b_1 conda-forge
sip 6.7.9 py38h17151c0_0 conda-forge
six 1.16.0 pyh6c4a22f_0 conda-forge
smart_open 6.3.0 pyhd8ed1ab_1 conda-forge
smmap 3.0.5 pyh44b312d_0 conda-forge
snakemake-minimal 7.26.0 pyhdfd78af_0 bioconda
snappy 1.1.10 h9fff704_0 conda-forge
sniffio 1.3.0 pyhd8ed1ab_0 conda-forge
snuggs 1.4.7 py_0 conda-forge
sortedcontainers 2.4.0 pyhd8ed1ab_0 conda-forge
soupsieve 2.3.2.post1 pyhd8ed1ab_0 conda-forge
sqlite 3.42.0 h2c6b66d_0 conda-forge
stack_data 0.6.2 pyhd8ed1ab_0 conda-forge
statsmodels 0.14.0 py38h31356c5_1 conda-forge
stopit 1.1.2 py_0 conda-forge
tabulate 0.9.0 pyhd8ed1ab_1 conda-forge
tblib 1.7.0 pyhd8ed1ab_0 conda-forge
terminado 0.17.1 pyh41d4057_0 conda-forge
threadpoolctl 3.1.0 pyh8a188c0_0 conda-forge
throttler 1.2.1 pyhd8ed1ab_0 conda-forge
tiledb 2.13.2 hd532e3d_0 conda-forge
tinycss2 1.2.1 pyhd8ed1ab_0 conda-forge
tk 8.6.12 h27826a3_0 conda-forge
toml 0.10.2 pyhd8ed1ab_0 conda-forge
tomli 2.0.1 pyhd8ed1ab_0 conda-forge
toolz 0.12.0 pyhd8ed1ab_0 conda-forge
toposort 1.10 pyhd8ed1ab_0 conda-forge
tornado 6.3.2 py38h01eb140_0 conda-forge
tqdm 4.65.0 pyhd8ed1ab_1 conda-forge
traitlets 5.9.0 pyhd8ed1ab_0 conda-forge
tsam 2.2.2 pypi_0 pypi
typing-extensions 4.6.3 hd8ed1ab_0 conda-forge
typing_extensions 4.6.3 pyha770c72_0 conda-forge
typing_utils 0.1.0 pyhd8ed1ab_0 conda-forge
tzcode 2023c h0b41bf4_0 conda-forge
tzdata 2023c h71feb2d_0 conda-forge
uc-micro-py 1.0.1 pyhd8ed1ab_0 conda-forge
ucx 1.14.1 hf587318_2 conda-forge
ukkonen 1.0.1 py38h43d8883_3 conda-forge
unicodedata2 15.0.0 py38h0a891b7_0 conda-forge
unidecode 1.3.6 pyhd8ed1ab_0 conda-forge
urllib3 2.0.2 pyhd8ed1ab_0 conda-forge
validators 0.20.0 pypi_0 pypi
virtualenv 20.23.0 pyhd8ed1ab_0 conda-forge
vresutils 0.3.2.dev11+g150c1be pypi_0 pypi
wcwidth 0.2.6 pyhd8ed1ab_0 conda-forge
webencodings 0.5.1 py_1 conda-forge
websocket-client 1.5.2 pyhd8ed1ab_0 conda-forge
wheel 0.40.0 pyhd8ed1ab_0 conda-forge
wrapt 1.15.0 py38h1de0b5d_0 conda-forge
xarray 2023.1.0 pyhd8ed1ab_0 conda-forge
xcb-util 0.4.0 h516909a_0 conda-forge
xcb-util-image 0.4.0 h166bdaf_0 conda-forge
xcb-util-keysyms 0.4.0 h516909a_0 conda-forge
xcb-util-renderutil 0.3.9 h166bdaf_0 conda-forge
xcb-util-wm 0.4.1 h516909a_0 conda-forge
xerces-c 3.2.4 h8d71039_2 conda-forge
xkeyboard-config 2.38 h0b41bf4_0 conda-forge
xlrd 2.0.1 pyhd8ed1ab_3 conda-forge
xorg-kbproto 1.0.7 h7f98852_1002 conda-forge
xorg-libice 1.1.1 hd590300_0 conda-forge
xorg-libsm 1.2.4 h7391055_0 conda-forge
xorg-libx11 1.8.4 h0b41bf4_0 conda-forge
xorg-libxau 1.0.11 hd590300_0 conda-forge
xorg-libxdmcp 1.1.3 h7f98852_0 conda-forge
xorg-libxext 1.3.4 h0b41bf4_2 conda-forge
xorg-libxrender 0.9.10 h7f98852_1003 conda-forge
xorg-renderproto 0.11.1 h7f98852_1002 conda-forge
xorg-xextproto 7.3.0 h0b41bf4_1003 conda-forge
xorg-xf86vidmodeproto 2.3.1 h7f98852_1002 conda-forge
xorg-xproto 7.0.31 h7f98852_1007 conda-forge
xyzservices 2023.5.0 pyhd8ed1ab_1 conda-forge
xz 5.2.6 h166bdaf_0 conda-forge
yaml 0.2.5 h7f98852_2 conda-forge
yaml-cpp 0.7.0 h27087fc_2 conda-forge
yte 1.5.1 pyha770c72_2 conda-forge
zeromq 4.3.4 h9c3ff4c_1 conda-forge
zict 3.0.0 pyhd8ed1ab_0 conda-forge
zipp 3.15.0 pyhd8ed1ab_0 conda-forge
zlib 1.2.13 h166bdaf_4 conda-forge
zlib-ng 2.0.7 h0b41bf4_0 conda-forge
zstandard 0.19.0 py38h5945529_1 conda-forge
zstd 1.5.2 h3eb15da_6 conda-forge

  ```
</details>
@davide-f
Copy link
Contributor Author

davide-f commented Jun 8, 2023

This issue does not appear with the environment with gdal <= 3.6 (3.5.2).

@davide-f
Copy link
Contributor Author

The issue relates to offshore wind time series (ac or dc) for a geometry that crosses the +-180 degrees.

@euronion
Copy link
Collaborator

So it only affects geometries crossing +/-180° ?

@euronion
Copy link
Collaborator

If you mention it works with gdal <= 3.6, which rasterio is installed with that gdal version? Might be rasterio related.

@ollie-bell
Copy link

Are there now any workarounds to building cutouts which cross +/- 180?

@euronion
Copy link
Collaborator

Not that I am aware of. Does the issue still persist for you? Or is the problem outdated?

@davide-f
Copy link
Contributor Author

davide-f commented Jul 4, 2024

This issue still persists. The workaround I found is avoid shapes that are multipolygons crossing the antimeridian.
It would be best to split them in two with the current implementation.

A long-term solution may be to change the procedure how atlite works and avoid the image cropping completely.
By exploiting a mapping function between the cutout and the geometry, it would be possible to sum only the numbers that lay wihin the region, without the need to perform the geometry operations.
In PyPSA-Earth we have an implementation for computing the population and could be adapted for atlite.
See: https://github.com/pypsa-meets-earth/pypsa-earth/blob/c1d4b993dc52d1f22a46efab983bcef5289afb95/scripts/build_shapes.py#L1114

That may solve the issue completely, but it requires effort

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ⚙️ In progress
Development

No branches or pull requests

3 participants