[go: up one dir, main page]

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

Vector plots draw an unintended constant longitude line about dateline #757

Open
1 task done
philipc2 opened this issue Oct 10, 2024 · 10 comments
Open
1 task done

Comments

@philipc2
Copy link
philipc2 commented Oct 10, 2024

ALL software version info

Software Version Info
# Name                    Version                   Build  Channel
abseil-cpp                20211102.0           h6b3803e_1    conda-forge
accessible-pygments       0.0.5                    pypi_0    pypi
alabaster                 1.0.0                    pypi_0    pypi
antimeridian              0.3.8              pyhd8ed1ab_0    conda-forge
anyio                     4.2.0           py311hca03da5_0  
anywidget                 0.9.13             pyhd8ed1ab_0    conda-forge
appnope                   0.1.2           py311hca03da5_1001  
archspec                  0.2.3              pyhd3eb1b0_0  
argon2-cffi               21.3.0             pyhd3eb1b0_0  
argon2-cffi-bindings      21.2.0          py311h80987f9_0  
arrow                     1.3.0                    pypi_0    pypi
arrow-cpp                 14.0.2               hc7aafb3_1  
asttokens                 2.0.5              pyhd3eb1b0_0  
asv                       0.6.4.dev13+gee3b187          pypi_0    pypi
asv-runner                0.2.1                    pypi_0    pypi
async-lru                 2.0.4           py311hca03da5_0  
attrs                     23.1.0          py311hca03da5_0  
aws-c-auth                0.6.19               h80987f9_0  
aws-c-cal                 0.5.20               h80987f9_0  
aws-c-common              0.8.5                h80987f9_0  
aws-c-compression         0.2.16               h80987f9_0  
aws-c-event-stream        0.2.15               h313beb8_0  
aws-c-http                0.6.25               h80987f9_0  
aws-c-io                  0.13.10              h80987f9_0  
aws-c-mqtt                0.7.13               h80987f9_0  
aws-c-s3                  0.1.51               h80987f9_0  
aws-c-sdkutils            0.1.6                h80987f9_0  
aws-checksums             0.1.13               h80987f9_0  
aws-crt-cpp               0.18.16              h313beb8_0  
aws-sdk-cpp               1.10.55              h313beb8_0  
babel                     2.16.0                   pypi_0    pypi
beautifulsoup4            4.12.3          py311hca03da5_0  
blas                      2.122                  openblas    conda-forge
blas-devel                3.9.0           22_osxarm64_openblas    conda-forge
bleach                    6.1.0              pyhd8ed1ab_0    conda-forge
blosc                     1.21.5               h9c252e8_1    conda-forge
bokeh                     3.5.2                    pypi_0    pypi
boltons                   23.0.0          py311hca03da5_0  
boost-cpp                 1.82.0               h48ca7d4_2  
bottleneck                1.3.7           py311hb9f6ed7_0  
branca                    0.7.2              pyhd8ed1ab_0    conda-forge
brotli                    1.0.9                h80987f9_8  
brotli-bin                1.0.9                h80987f9_8  
brotli-python             1.0.9           py311h313beb8_8  
build                     0.9.0                    pypi_0    pypi
bzip2                     1.0.8                h80987f9_6  
c-ares                    1.32.2               h99b78c6_0    conda-forge
ca-certificates           2024.8.30            hf0a4a13_0    conda-forge
cairo                     1.16.0               h302bd0f_5  
cartopy                   0.22.0          py311h7aedaa7_0  
certifi                   2024.8.30          pyhd8ed1ab_0    conda-forge
cffi                      1.16.0          py311h80987f9_1  
cfgv                      3.4.0                    pypi_0    pypi
cfitsio                   3.470                ha83d327_7    conda-forge
cftime                    1.6.2           py311ha0d4635_0  
charset-normalizer        3.3.2              pyhd8ed1ab_0    conda-forge
click                     8.1.7           unix_pyh707e725_0    conda-forge
click-plugins             1.1.1                      py_0    conda-forge
cligj                     0.7.2              pyhd8ed1ab_1    conda-forge
cloudpickle               3.0.0              pyhd8ed1ab_0    conda-forge
colorama                  0.4.6              pyhd8ed1ab_0    conda-forge
colorcet                  3.1.0              pyhd8ed1ab_0    conda-forge
comm                      0.2.1           py311hca03da5_0  
conda                     24.9.1          py311h267d04e_0    conda-forge
conda-libmamba-solver     24.1.0             pyhd3eb1b0_0  
conda-package-handling    2.3.0           py311hca03da5_0  
conda-package-streaming   0.10.0          py311hca03da5_0  
contourpy                 1.2.0           py311h48ca7d4_0  
cycler                    0.12.1             pyhd8ed1ab_0    conda-forge
cyrus-sasl                2.1.28               h9131b1a_1  
cytoolz                   0.12.2          py311h80987f9_0  
dask                      2024.7.0           pyhd8ed1ab_0    conda-forge
dask-core                 2024.7.0           pyhd8ed1ab_0    conda-forge
dask-expr                 1.1.7              pyhd8ed1ab_0    conda-forge
datashader                0.16.3             pyhd8ed1ab_0    conda-forge
debugpy                   1.6.7           py311h313beb8_0  
decorator                 5.1.1              pyhd3eb1b0_0  
defusedxml                0.7.1              pyhd3eb1b0_0  
distlib                   0.3.8                    pypi_0    pypi
distributed               2024.7.0           pyhd8ed1ab_0    conda-forge
distro                    1.9.0           py311hca03da5_0  
docutils                  0.21.2                   pypi_0    pypi
executing                 0.8.3              pyhd3eb1b0_0  
expat                     2.6.3                hf9b8971_0    conda-forge
filelock                  3.15.4                   pypi_0    pypi
fiona                     1.9.1           py311habcf648_0    conda-forge
fmt                       9.1.0                hffc8910_0    conda-forge
folium                    0.17.0             pyhd8ed1ab_0    conda-forge
fontconfig                2.14.1               hee714a5_2  
fonttools                 4.25.0             pyhd3eb1b0_0  
fqdn                      1.5.1                    pypi_0    pypi
freetype                  2.10.4               h17b34a0_1    conda-forge
freexl                    2.0.0                ha3de405_0  
frozendict                2.4.2           py311hca03da5_0  
fsspec                    2024.6.1           pyhff2d567_0    conda-forge
gdal                      3.6.2           py311h950983f_4  
geocat-datafiles          2022.03.0          pyha770c72_0    conda-forge
geopandas                 1.0.1                    pypi_0    pypi
geos                      3.9.1                h9f76cd9_2    conda-forge
geotiff                   1.7.0                h41f0982_3  
geoviews                  1.13.0                   pypi_0    pypi
gettext                   0.21.0               h13f89a0_1  
gflags                    2.2.2             hc88da5d_1004    conda-forge
giflib                    5.2.2                h93a5062_0    conda-forge
glib                      2.78.4               h313beb8_0  
glib-tools                2.78.4               h313beb8_0  
glog                      0.5.0                h5c6a83d_0    conda-forge
grpc-cpp                  1.48.2               hc60591f_1  
gst-plugins-base          1.14.1               h313beb8_1  
gstreamer                 1.14.1               h80987f9_1  
hdf4                      4.2.13               h5e329fb_3  
hdf5                      1.12.1               h05c076b_3  
holoviews                 1.19.1             pyhd8ed1ab_0    conda-forge
hvplot                    0.11.0                   pypi_0    pypi
icu                       73.1                 h313beb8_0  
identify                  2.6.0                    pypi_0    pypi
idna                      3.7                pyhd8ed1ab_0    conda-forge
imagesize                 1.4.1                    pypi_0    pypi
importlib-metadata        8.0.0              pyha770c72_0    conda-forge
importlib_metadata        8.0.0                hd8ed1ab_0    conda-forge
iniconfig                 1.1.1              pyhd3eb1b0_0  
ipykernel                 6.28.0          py311hca03da5_0  
ipython                   8.25.0          py311hca03da5_0  
ipywidgets                8.1.2           py311hca03da5_0  
isoduration               20.11.0                  pypi_0    pypi
jedi                      0.19.1          py311hca03da5_0  
jinja2                    3.1.4              pyhd8ed1ab_0    conda-forge
joblib                    1.4.2              pyhd8ed1ab_0    conda-forge
jpeg                      9e                   h1a8c8d9_3    conda-forge
json-c                    0.16                 hc449e50_0    conda-forge
json5                     0.9.6              pyhd3eb1b0_0  
jsonpatch                 1.33            py311hca03da5_1  
jsonpointer               2.1                pyhd3eb1b0_0  
jsonschema                4.19.2          py311hca03da5_0  
jsonschema-specifications 2023.7.1        py311hca03da5_0  
jupyter                   1.0.0           py311hca03da5_9  
jupyter-cache             1.0.0                    pypi_0    pypi
jupyter-lsp               2.2.0           py311hca03da5_0  
jupyter_client            8.6.0           py311hca03da5_0  
jupyter_console           6.6.3           py311hca03da5_0  
jupyter_core              5.7.2           py311hca03da5_0  
jupyter_events            0.10.0          py311hca03da5_0  
jupyter_server            2.14.1          py311hca03da5_0  
jupyter_server_terminals  0.4.4           py311hca03da5_1  
jupyterlab                4.0.11          py311hca03da5_0  
jupyterlab-spellchecker   0.8.4                    pypi_0    pypi
jupyterlab_pygments       0.1.2                      py_0  
jupyterlab_server         2.25.1          py311hca03da5_0  
jupyterlab_widgets        3.0.10          py311hca03da5_0  
kealib                    1.5.0                hba2eb73_1  
kiwisolver                1.4.4           py311h313beb8_0  
krb5                      1.20.1               h69eda48_0    conda-forge
lcms2                     2.12                 hba8e193_0  
lerc                      3.0                  hc377ac9_0  
libarchive                3.6.2                h62fee54_3  
libblas                   3.9.0           22_osxarm64_openblas    conda-forge
libboost                  1.82.0               h0bc93f9_2  
libboost-headers          1.82.0               hce30654_6    conda-forge
libbrotlicommon           1.0.9                h80987f9_8  
libbrotlidec              1.0.9                h80987f9_8  
libbrotlienc              1.0.9                h80987f9_8  
libcblas                  3.9.0           22_osxarm64_openblas    conda-forge
libclang                  14.0.6          default_h1b80db6_1  
libclang13                14.0.6          default_h24352ff_1  
libcurl                   8.7.1                h3e2b118_0  
libcxx                    18.1.8               h167917d_0    conda-forge
libdeflate                1.17                 h80987f9_1  
libedit                   3.1.20230828         h80987f9_0  
libev                     4.33                 h93a5062_2    conda-forge
libevent                  2.1.12               h2757513_1    conda-forge
libexpat                  2.6.3                hf9b8971_0    conda-forge
libffi                    3.4.4                hca03da5_1  
libgdal                   3.6.2                h0413ea8_4  
libgfortran               5.0.0           13_2_0_hd922786_3    conda-forge
libgfortran5              13.2.0               hf226fd6_3    conda-forge
libglib                   2.78.4               h0a96307_0  
libiconv                  1.16                 h80987f9_3  
libkml                    1.3.0             h1eb4d9f_1018    conda-forge
liblapack                 3.9.0           22_osxarm64_openblas    conda-forge
liblapacke                3.9.0           22_osxarm64_openblas    conda-forge
libllvm14                 14.0.6               h7ec7a93_3  
libmamba                  1.5.8                haeffa04_2  
libmambapy                1.5.8           py311h1c5506f_2  
libnetcdf                 4.8.1                h0fce390_4  
libnghttp2                1.57.0               h62f6fdd_0  
libopenblas               0.3.27          openmp_h517c56d_1    conda-forge
libpng                    1.6.39               h80987f9_0  
libpq                     12.17                h02f6b3c_0  
libprotobuf               3.20.3               h514c7bf_0  
libsodium                 1.0.18               h1a28f6b_0  
libsolv                   0.7.24               h514c7bf_1  
libspatialindex           2.0.0                h00cdb27_0    conda-forge
libspatialite             5.1.0                h87e580a_0  
libsqlite                 3.46.0               hfb93653_0    conda-forge
libssh2                   1.11.0               h3e2b118_0  
libthrift                 0.15.0               h73c2103_2  
libtiff                   4.5.1                h313beb8_0  
libwebp-base              1.4.0                h93a5062_0    conda-forge
libxml2                   2.10.4               h0b34f26_2  
libzip                    1.8.0                h62fee54_1  
libzlib                   1.2.13               hfb2fe0b_6    conda-forge
linkify-it-py             2.0.3              pyhd8ed1ab_0    conda-forge
llvm-openmp               18.1.8               hde57baf_0    conda-forge
llvmlite                  0.43.0          py311h313beb8_0  
locket                    1.0.0              pyhd8ed1ab_0    conda-forge
lonboard                  0.9.3              pyh5bfe37b_0    conda-forge
lz4                       4.3.2           py311h80987f9_0  
lz4-c                     1.9.4                hb7217d7_0    conda-forge
mapclassify               2.8.0              pyhd8ed1ab_0    conda-forge
markdown                  3.6                pyhd8ed1ab_0    conda-forge
markdown-it-py            3.0.0              pyhd8ed1ab_0    conda-forge
markupsafe                2.1.3           py311h80987f9_0  
matplotlib-base           3.8.4           py311h7aedaa7_0  
matplotlib-inline         0.1.7              pyhd8ed1ab_0    conda-forge
mdit-py-plugins           0.4.1              pyhd8ed1ab_0    conda-forge
mdurl                     0.1.2              pyhd8ed1ab_0    conda-forge
menuinst                  2.1.1           py311hca03da5_0  
minizip                   4.0.3                ha89c15f_0  
mistune                   2.0.4           py311hca03da5_0  
msgpack-python            1.0.3           py311h48ca7d4_0  
multipledispatch          0.6.0                      py_0    conda-forge
munch                     4.0.0              pyhd8ed1ab_0    conda-forge
munkres                   1.1.4              pyh9f0ad1d_0    conda-forge
mysql                     5.7.24               ha71a6ea_2  
myst-nb                   1.1.2                    pypi_0    pypi
myst-parser               4.0.0                    pypi_0    pypi
nbclient                  0.8.0           py311hca03da5_0  
nbconvert                 7.10.0          py311hca03da5_0  
nbformat                  5.9.2           py311hca03da5_0  
nbsphinx                  0.9.5                    pypi_0    pypi
ncurses                   6.4                  h313beb8_0  
nest-asyncio              1.6.0           py311hca03da5_0  
netcdf4                   1.6.2           py311h55fefbe_0  
networkx                  3.3                pyhd8ed1ab_1    conda-forge
nodeenv                   1.9.1                    pypi_0    pypi
notebook                  7.0.8           py311hca03da5_2  
notebook-shim             0.2.3           py311hca03da5_0  
nspr                      4.35                 hb7217d7_0    conda-forge
nss                       3.100                hc6e9f88_0    conda-forge
numba                     0.60.0          py311h7aedaa7_0  
numexpr                   2.8.7           py311h6dc990b_0  
numpy                     1.26.4          py311he598dae_0  
numpy-base                1.26.4          py311hfbfe69c_0  
openblas                  0.3.27          openmp_h560b219_1    conda-forge
openjpeg                  2.4.0                h0ed58ac_2  
openssl                   3.3.2                h8359307_0    conda-forge
orc                       1.7.4                hdca1487_1  
overrides                 7.4.0           py311hca03da5_0  
packaging                 24.1               pyhd8ed1ab_0    conda-forge
palettable                3.3.3              pyhd8ed1ab_0    conda-forge
pandas                    2.0.3                    pypi_0    pypi
pandocfilters             1.5.0              pyhd3eb1b0_0  
panel                     1.5.2                    pypi_0    pypi
param                     2.1.1              pyhff2d567_0    conda-forge
parso                     0.8.3              pyhd3eb1b0_0  
partd                     1.4.2              pyhd8ed1ab_0    conda-forge
pcre2                     10.42                hb066dcc_1  
pep517                    0.13.1                   pypi_0    pypi
pexpect                   4.8.0              pyhd3eb1b0_3  
pillow                    10.4.0          py311h80987f9_0  
pip                       24.0            py311hca03da5_0  
pixman                    0.43.4               hebf3989_0    conda-forge
platformdirs              3.10.0          py311hca03da5_0  
pluggy                    1.0.0           py311hca03da5_1  
ply                       3.11            py311hca03da5_0  
pooch                     1.8.2              pyhd8ed1ab_0    conda-forge
poppler                   22.12.0              h52f4003_3  
poppler-data              0.4.12               hd8ed1ab_0    conda-forge
pre-commit                3.7.1                    pypi_0    pypi
proj                      9.3.1                h805f6d4_0  
prometheus_client         0.14.1          py311hca03da5_0  
prompt-toolkit            3.0.43          py311hca03da5_0  
prompt_toolkit            3.0.43               hd3eb1b0_0  
psutil                    5.9.0           py311h80987f9_0  
psygnal                   0.11.1             pyhd8ed1ab_0    conda-forge
ptyprocess                0.7.0              pyhd3eb1b0_2  
pure_eval                 0.2.2              pyhd3eb1b0_0  
pyarrow                   14.0.2          py311ha07b5f9_0  
pyarrow-hotfix            0.6                pyhd8ed1ab_0    conda-forge
pybind11-abi              4                    hd8ed1ab_3    conda-forge
pycosat                   0.6.6           py311h80987f9_1  
pycparser                 2.21               pyhd3eb1b0_0  
pyct                      0.5.0              pyhd8ed1ab_0    conda-forge
pydata-sphinx-theme       0.15.4                   pypi_0    pypi
pyfma                     0.1.6                    pypi_0    pypi
pygments                  2.18.0                   pypi_0    pypi
pympler                   1.1                      pypi_0    pypi
pyogrio                   0.9.0                    pypi_0    pypi
pyparsing                 3.0.9              pyhd8ed1ab_0    conda-forge
pyproj                    3.6.1           py311h041c639_0  
pyproject-hooks           1.1.0                    pypi_0    pypi
pyproject_hooks           1.0.0           py311hca03da5_0  
pyqt                      5.15.10         py311h313beb8_0  
pyqt5-sip                 12.13.0         py311h80987f9_0  
pyshp                     2.3.1              pyhd8ed1ab_0    conda-forge
pysocks                   1.7.1              pyha2e5f31_6    conda-forge
pytest                    7.4.4           py311hca03da5_0  
python                    3.11.8          hdf0ec26_0_cpython    conda-forge
python-dateutil           2.9.0              pyhd8ed1ab_0    conda-forge
python-fastjsonschema     2.16.2          py311hca03da5_0  
python-json-logger        2.0.7           py311hca03da5_0  
python-tzdata             2024.1             pyhd8ed1ab_0    conda-forge
python_abi                3.11                    5_cp311    conda-forge
pytz                      2024.1             pyhd8ed1ab_0    conda-forge
pyviz_comms               3.0.2              pyhd8ed1ab_1    conda-forge
pyyaml                    6.0.1           py311h80987f9_0  
pyzmq                     25.1.2          py311h313beb8_0  
qhull                     2020.2               h420ef59_5    conda-forge
qt-main                   5.15.2              h0917680_10  
qtconsole                 5.5.1           py311hca03da5_0  
qtpy                      2.4.1           py311hca03da5_0  
re2                       2022.04.01           h6b3803e_0    conda-forge
readline                  8.2                  h1a28f6b_0  
referencing               0.30.2          py311hca03da5_0  
reproc                    14.2.4.post0         h93a5062_1    conda-forge
reproc-cpp                14.2.4.post0         h965bd2d_1    conda-forge
requests                  2.32.3             pyhd8ed1ab_0    conda-forge
retrying                  1.3.3                      py_2    conda-forge
rfc3339-validator         0.1.4           py311hca03da5_0  
rfc3986-validator         0.1.1           py311hca03da5_0  
rpds-py                   0.10.6          py311hf0e4da2_0  
rtree                     1.3.0           py311hc46b6d3_2    conda-forge
ruamel.yaml               0.17.21         py311h80987f9_0  
scikit-learn              1.4.2           py311h7aedaa7_1  
scipy                     1.13.1          py311hac8794a_0  
send2trash                1.8.2           py311hca03da5_0  
setuptools                69.5.1          py311hca03da5_0  
shapely                   2.0.1           py311h3713c0e_0  
sip                       6.7.12          py311h313beb8_0  
six                       1.16.0             pyh6c4a22f_0    conda-forge
snappy                    1.2.1                hd02b534_0    conda-forge
sniffio                   1.3.0           py311hca03da5_0  
snowballstemmer           2.2.0                    pypi_0    pypi
sortedcontainers          2.4.0              pyhd8ed1ab_0    conda-forge
soupsieve                 2.5             py311hca03da5_0  
spatialpandas             0.4.10             pyhd8ed1ab_1    conda-forge
sphinx                    8.0.2                    pypi_0    pypi
sphinx-autosummary-accessors 2023.4.0                 pypi_0    pypi
sphinx-book-theme         1.1.3                    pypi_0    pypi
sphinx-design             0.6.1                    pypi_0    pypi
sphinx-remove-toctrees    1.0.0.post1              pypi_0    pypi
sphinxcontrib-applehelp   2.0.0                    pypi_0    pypi
sphinxcontrib-devhelp     2.0.0                    pypi_0    pypi
sphinxcontrib-htmlhelp    2.1.0                    pypi_0    pypi
sphinxcontrib-jsmath      1.0.1                    pypi_0    pypi
sphinxcontrib-qthelp      2.0.0                    pypi_0    pypi
sphinxcontrib-serializinghtml 2.0.0                    pypi_0    pypi
sqlalchemy                2.0.35                   pypi_0    pypi
sqlite                    3.45.3               h80987f9_0  
stack_data                0.2.0              pyhd3eb1b0_0  
tabulate                  0.9.0                    pypi_0    pypi
tbb                       2021.8.0             h48ca7d4_0  
tblib                     3.0.0              pyhd8ed1ab_0    conda-forge
terminado                 0.17.1          py311hca03da5_0  
threadpoolctl             3.5.0              pyhc1e730c_0    conda-forge
tiledb                    2.3.3                hb4a6b97_3  
tinycss2                  1.2.1           py311hca03da5_0  
tk                        8.6.14               h6ba3021_0  
toolz                     0.12.1             pyhd8ed1ab_0    conda-forge
tornado                   6.4.1           py311h80987f9_0  
tqdm                      4.66.4             pyhd8ed1ab_0    conda-forge
traitlets                 5.14.3             pyhd8ed1ab_0    conda-forge
truststore                0.8.0           py311hca03da5_0  
types-python-dateutil     2.9.0.20240906           pypi_0    pypi
typing-extensions         4.11.0          py311hca03da5_0  
typing_extensions         4.11.0          py311hca03da5_0  
tzdata                    2024a                h04d1e81_0  
uc-micro-py               1.0.3              pyhd8ed1ab_0    conda-forge
uri-template              1.3.0                    pypi_0    pypi
uriparser                 0.9.8                h00cdb27_0    conda-forge
urllib3                   2.2.2              pyhd8ed1ab_0    conda-forge
utf8proc                  2.6.1                h80987f9_1  
uxarray                   2024.8.3.dev168+g8a1cdc40.d20241010          pypi_0    pypi
virtualenv                20.26.3                  pypi_0    pypi
watchfiles                0.24.0          py311h481aa64_1    conda-forge
wcwidth                   0.2.5              pyhd3eb1b0_0  
webcolors                 24.8.0                   pypi_0    pypi
webencodings              0.5.1              pyhd8ed1ab_2    conda-forge
websocket-client          1.8.0           py311hca03da5_0  
wheel                     0.43.0          py311hca03da5_0  
widgetsnbextension        4.0.10          py311hca03da5_0  
wrapt                     1.16.0          py311h460d6c5_1    conda-forge
xarray                    2024.6.0           pyhd8ed1ab_1    conda-forge
xerces-c                  3.2.4                h313beb8_1  
xyzservices               2024.6.0           pyhd8ed1ab_0    conda-forge
xz                        5.4.6                h80987f9_1  
yaml                      0.2.5                h3422bc3_2    conda-forge
yaml-cpp                  0.8.0                h13dd4ca_0    conda-forge
zeromq                    4.3.5                h313beb8_0  
zict                      3.0.0              pyhd8ed1ab_0    conda-forge
zipp                      3.19.2             pyhd8ed1ab_0    conda-forge
zlib                      1.2.13               hfb2fe0b_6    conda-forge
zstandard                 0.22.0          py311h1a4646a_0  
zstd                      1.5.5                hd90d995_2  

Description of expected behavior and the observed behavior

I am working with a mesh of polygons that I want to project and visualize over the dateline (180 degrees longitude). I have two datasets:

  • Unprojected GeoDataFrame excluding elements that are on the Dateline
  • GeoDataFrame with elements shifted by 180 degrees.

I've put a few code examples below. For vector plots, there is line of longitude being drawn at 180 degrees, which is not observed in the rasterized plot or the un-projected one.

With the elements

Complete, minimal, self-contained example code that reproduces the issue

import hvplot.pandas
import cartopy.crs as ccrs

Shapefile of gdf_0_lon: https://drive.google.com/file/d/1i35d7tCvXOTm1EcmHsKHWn3iTHIHUNm2/view?usp=drive_link

Shapefile of gdf_180_lon: https://drive.google.com/file/d/12hYPfCbDpc0gv7ohzX_yKdxufOC1dWos/view?usp=drive_link

projection = ccrs.Orthographic(central_longitude=180)
crs = ccrs.PlateCarree()
gdf_0_lon.hvplot.paths(geo=True, crs=crs, projection=projection, global_extent=True)
image
projection = ccrs.Orthographic(central_longitude=180)
crs = ccrs.PlateCarree(central_longitude=180)
gdf_180_lon.hvplot.paths(geo=True, crs=crs, projection=projection, global_extent=True)
image
projection = ccrs.Orthographic(central_longitude=180)
crs = ccrs.PlateCarree(central_longitude=180)
gdf_180_lon.hvplot.paths(geo=True, crs=crs, projection=projection, global_extent=True, rasterize=True, dynamic=False, pixel_ratio=4.0, line_width=4, colorbar=False,)
image
gdf_180_lon.hvplot.paths()
image

Stack traceback and/or browser JavaScript console output

N/A

  • I may be interested in making a pull request to address this
@philipc2
Copy link
Author

The same behavior is observed with geoviews

import geoviews as gv

projection = ccrs.Orthographic(central_longitude=180)
crs = ccrs.PlateCarree(central_longitude=180)

gv.Path(gdf_180_lon, crs=crs).opts(projection=projection)
image

@ahuang11
Copy link
Collaborator

Can you see if matplotlib does the same?

@philipc2
Copy link
Author

Can you see if matplotlib does the same?

Same behavior.

import geoviews as gv
import holoviews as hv
hv.extension("matplotlib")

projection = ccrs.Orthographic(central_longitude=180)
crs = ccrs.PlateCarree(central_longitude=180)

gv.Path(gdf_180_lon, crs=crs).opts(projection=projection)
image

@ahuang11
Copy link
Collaborator

Oh I meant pure matplotlib :P

@philipc2
Copy link
Author

Oh I meant pure matplotlib :P

Oops! Here's a Matplotlib plot using a PolyCollection. There's some UXarray logic here, though the GeoDataFrames I generated above were also from UXarray.

projection = ccrs.Orthographic(central_longitude=180)
crs = ccrs.PlateCarree(central_longitude=180)

# shift central coordinates by applying a PlateCarree at 180 degrees
pc = uxds['bottomDepth'].to_polycollection(periodic_elements="exclude", projection=crs)

pc.set_antialiased(True)
pc.set_cmap("Blues")


fig, ax = plt.subplots(
    1,
    1,
    figsize=(10, 5),
    facecolor="w",
    constrained_layout=True,
    subplot_kw=dict(projection=projection), # project using matplotlib, with source PlateCarree at 180 lon
)

ax.add_feature(cfeature.COASTLINE)
ax.add_feature(cfeature.BORDERS)

ax.add_collection(pc)
ax.set_global()
image

Switching subplot_kw=dict(projection=projection) to `subplot_kw=dict(projection=crs) yeilds the following:
image

@ahuang11
Copy link
Collaborator

So it seems like there's something wrong with GeoViews projecting it. Moving to geoviews.

@ahuang11 ahuang11 transferred this issue from holoviz/hvplot Oct 17, 2024
@ahuang11
Copy link
Collaborator

Maybe you can poke around here and see if you can spot the issue here:
https://github.com/holoviz/geoviews/blob/main/geoviews/util.py#L54-L115

@philipc2
Copy link
Author

Maybe you can poke around here and see if you can spot the issue here: https://github.com/holoviz/geoviews/blob/main/geoviews/util.py#L54-L115

Will take a look!

@philipc2
Copy link
Author

Initially I was thinking that the line may be a reside of the frame surround the plot. After setting the following, the line is still there.

backend_opts={
    "axes.frame_on": True,
}

@ahuang11
Copy link
Collaborator

It's likely related to

https://stackoverflow.com/questions/56348136/white-line-in-contour-plot-in-cartopy-on-center-longitude

cartopy / matplotlib likely does something internally to fill it(?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants