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

Cartopy failling when using DataArray directly #2049

Closed
axnsantana opened this issue May 23, 2022 · 2 comments
Closed

Cartopy failling when using DataArray directly #2049

axnsantana opened this issue May 23, 2022 · 2 comments
Milestone

Comments

@axnsantana
Copy link
Contributor

Description

Hi,

Trying to plot some data using xarray's DataArray structure, cartopy fails because it expects (implicitly) the input data to be a numpy array. There is a similar discussion/issue here, here, and a fixing here.

We could follow the Numpy solution and apply it to Cartopy, calling asanyarray on the input data.

Code to reproduce

import xarray as xr
import numpy as np
import matplotlib.pyplot as plt
import cartopy.crs as ccrs
import cartopy

w = 3
Y, X = np.mgrid[-w:w:100j, -w:w:100j]
U = -1 - X**2 + Y
V = 1 + X - Y**2
speed = np.sqrt(U**2 + V**2)

lons = np.linspace(0, 5, np.shape(Y)[0])
lats = np.linspace(37, 42, np.shape(Y)[0])

xarray_field = xr.Dataset(
    {
        "u_velocity": (["latitude", "longitude"], U),
        "v_velocity": (["latitude", "longitude"], V),
        "speed": (["latitude", "longitude"], speed)
    },
    coords={
        "longitude": lons,
        "latitude": lats
    })

fig, ax = plt.subplots(nrows=1, ncols=1,
                       subplot_kw={'projection': ccrs.PlateCarree()})
xarray_field.speed.plot(ax=ax)
sp = ax.streamplot(xarray_field["longitude"], xarray_field["latitude"], xarray_field["u_velocity"], xarray_field["v_velocity"], color="w")

plt.show()

Traceback

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
Input In [5], in <cell line: 4>()
      1 fig, ax = plt.subplots(nrows=1, ncols=1,
      2                        subplot_kw={'projection': ccrs.PlateCarree()})
      3 xarray_field.speed.plot(ax=ax)
----> 4 sp = ax.streamplot(xarray_field["longitude"], xarray_field["latitude"], xarray_field["u_velocity"], xarray_field["v_velocity"], color="w")
      6 plt.show()

File ~/miniconda3/lib/python3.8/site-packages/cartopy/mpl/geoaxes.py:318, in _add_transform.<locals>.wrapper(self, *args, **kwargs)
    313     raise ValueError(f'Invalid transform: Spherical {func.__name__} '
    314                      'is not supported - consider using '
    315                      'PlateCarree/RotatedPole.')
    317 kwargs['transform'] = transform
--> 318 return func(self, *args, **kwargs)

File ~/miniconda3/lib/python3.8/site-packages/cartopy/mpl/geoaxes.py:2240, in GeoAxes.streamplot(self, x, y, u, v, **kwargs)
   2237 # Lazy load vector_scalar_to_grid due to the optional
   2238 # scipy dependency
   2239 from cartopy.vector_transform import vector_scalar_to_grid
-> 2240 gridded = vector_scalar_to_grid(t, self.projection, regrid_shape,
   2241                                 x, y, u, v, *scalars,
   2242                                 target_extent=target_extent)
   2243 x, y, u, v = gridded[:4]
   2244 # If scalar fields were regridded then replace the appropriate keyword
   2245 # arguments with the gridded arrays.

File ~/miniconda3/lib/python3.8/site-packages/cartopy/vector_transform.py:130, in vector_scalar_to_grid(src_crs, target_proj, regrid_shape, x, y, u, v, *scalars, **kwargs)
    127     nx = ny = regrid_shape
    128 if target_proj == src_crs:
    129     # Just immediately regrid, interpolate and return
--> 130     return _interpolate_to_grid(nx, ny, x, y, u, v, *scalars, **kwargs)
    132 # We need to transform the vectors from the source to target frame
    133 # Convert coordinates to the target projection.
    134 proj_xyz = target_proj.transform_points(src_crs, x, y)

File ~/miniconda3/lib/python3.8/site-packages/cartopy/vector_transform.py:57, in _interpolate_to_grid(nx, ny, x, y, *scalars, **kwargs)
     55 s_grid_tuple = tuple()
     56 for s in scalars:
---> 57     s_grid_tuple += (griddata(points, s.ravel(), (x_grid, y_grid),
     58                               method='linear'),)
     59 return (x_grid * xr + x0, y_grid * yr + y0) + s_grid_tuple

File ~/miniconda3/lib/python3.8/site-packages/xarray/core/common.py:239, in AttrAccessMixin.__getattr__(self, name)
    237         with suppress(KeyError):
    238             return source[name]
--> 239 raise AttributeError(
    240     f"{type(self).__name__!r} object has no attribute {name!r}"
    241 )

AttributeError: 'DataArray' object has no attribute 'ravel'
Full environment definition

Operating system

Linux mini 5.4.0-110-generic #124-Ubuntu SMP Thu Apr 14 19:46:19 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Cartopy version

0.20.2

conda list

# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       1_gnu    conda-forge
alsa-lib                  1.2.3                h516909a_0    conda-forge
anyio                     3.5.0            py38h578d9bd_0    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_2    conda-forge
asttokens                 2.0.5              pyhd8ed1ab_0    conda-forge
async_generator           1.10                       py_0    conda-forge
attrs                     21.4.0             pyhd8ed1ab_0    conda-forge
babel                     2.9.1              pyh44b312d_0    conda-forge
backcall                  0.2.0              pyh9f0ad1d_0    conda-forge
backports                 1.1                pyhd3eb1b0_0  
backports.functools_lru_cache 1.6.4              pyhd8ed1ab_0    conda-forge
beautifulsoup4            4.9.3              pyhb0f4dca_0    conda-forge
binutils_impl_linux-64    2.36.1               h193b22a_2    conda-forge
binutils_linux-64         2.36                 hf3e587d_9    conda-forge
black                     22.3.0             pyhd8ed1ab_0    conda-forge
bleach                    5.0.0              pyhd8ed1ab_0    conda-forge
blosc                     1.21.0               h9c3ff4c_0    conda-forge
bokeh                     2.4.2            py38h578d9bd_1    conda-forge
boost-cpp                 1.74.0               h6cacc03_7    conda-forge
brotli                    1.0.9                h166bdaf_7    conda-forge
brotli-bin                1.0.9                h166bdaf_7    conda-forge
brotlipy                  0.7.0           py38h0a891b7_1004    conda-forge
bs4                       4.9.3                         0    conda-forge
bzip2                     1.0.8                h7f98852_4    conda-forge
c-ares                    1.18.1               h7f98852_0    conda-forge
ca-certificates           2022.4.26            h06a4308_0  
cached-property           1.5.2                hd8ed1ab_1    conda-forge
cached_property           1.5.2              pyha770c72_1    conda-forge
cachetools                5.0.0              pyhd8ed1ab_0    conda-forge
cairo                     1.16.0            ha12eb4b_1010    conda-forge
cartopy                   0.20.2           py38h51d8e34_4    conda-forge
certifi                   2021.10.8        py38h578d9bd_2    conda-forge
cffi                      1.15.0           py38h3931269_0    conda-forge
cfgrib                    0.9.9.0            pyhd8ed1ab_1    conda-forge
cfitsio                   4.1.0                hd9d235c_0    conda-forge
cftime                    1.6.0            py38h71d37f0_1    conda-forge
cgen                      2020.1                     py_0    conda-forge
charset-normalizer        2.0.12             pyhd8ed1ab_0    conda-forge
click                     8.1.2            py38h578d9bd_0    conda-forge
click-plugins             1.1.1                      py_0    conda-forge
cligj                     0.7.2              pyhd8ed1ab_1    conda-forge
cloudpickle               2.0.0              pyhd8ed1ab_0    conda-forge
cmocean                   2.0                        py_3    conda-forge
colorama                  0.4.4              pyh9f0ad1d_0    conda-forge
colorcet                  3.0.0              pyhd8ed1ab_0    conda-forge
colorspacious             1.1.2              pyh24bf2e0_0    conda-forge
conda                     4.12.0           py38h578d9bd_0    conda-forge
conda-package-handling    1.8.1            py38h0a891b7_1    conda-forge
cryptography              36.0.0           py38h9ce1e76_0  
curl                      7.82.0               h2283fc2_0    conda-forge
cycler                    0.11.0             pyhd8ed1ab_0    conda-forge
cytoolz                   0.11.2           py38h0a891b7_2    conda-forge
dask                      2022.4.1           pyhd8ed1ab_0    conda-forge
dask-core                 2022.4.1           pyhd8ed1ab_0    conda-forge
dataclasses               0.8                pyhc8e2a94_3    conda-forge
datashader                0.13.0             pyh6c4a22f_0    conda-forge
datashape                 0.5.4                      py_1    conda-forge
dbus                      1.13.18              hb2f20db_0  
debugpy                   1.6.0            py38hfa26641_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
distributed               2022.4.1           pyhd8ed1ab_0    conda-forge
distro                    1.5.0              pyh9f0ad1d_0    conda-forge
eccodes                   2.25.0               hc08acdf_0    conda-forge
entrypoints               0.4                pyhd8ed1ab_0    conda-forge
et_xmlfile                1.1.0            py38h06a4308_0  
executing                 0.8.3              pyhd8ed1ab_0    conda-forge
expat                     2.4.8                h27087fc_0    conda-forge
fiona                     1.8.21           py38ha349e16_1    conda-forge
flake8                    3.9.1              pyhd8ed1ab_0    conda-forge
flask                     1.1.2              pyh9f0ad1d_0    conda-forge
flit-core                 3.7.1              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.0               h8e229c2_0    conda-forge
fonts-conda-ecosystem     1                             0    conda-forge
fonts-conda-forge         1                             0    conda-forge
fonttools                 4.32.0           py38h0a891b7_0    conda-forge
freeglut                  3.2.2                h9c3ff4c_1    conda-forge
freetype                  2.11.0               h70c0345_0  
freexl                    1.0.6                h7f98852_0    conda-forge
fsspec                    2022.3.0           pyhd8ed1ab_0    conda-forge
gcc_impl_linux-64         11.2.0              h82a94d6_15    conda-forge
gcc_linux-64              11.2.0               h39a9532_9    conda-forge
gdal                      3.4.2            py38h51ade5a_6    conda-forge
geographiclib             1.52               pyhd8ed1ab_0    conda-forge
geopandas                 0.9.0              pyhd8ed1ab_1    conda-forge
geopandas-base            0.9.0              pyhd8ed1ab_1    conda-forge
geopy                     2.1.0              pyhd3deb0d_0    conda-forge
geos                      3.10.2               h9c3ff4c_0    conda-forge
geotiff                   1.7.1                h509b78c_1    conda-forge
gettext                   0.21.0               hf68c758_0  
giflib                    5.2.1                h36c2ea0_2    conda-forge
glib                      2.70.2               h780b84a_4    conda-forge
glib-tools                2.70.2               h780b84a_4    conda-forge
gst-plugins-base          1.20.1               hcf0ee16_1    conda-forge
gstreamer                 1.20.1               hd4edc92_1    conda-forge
h11                       0.13.0             pyhd8ed1ab_0    conda-forge
h5netcdf                  1.0.0              pyhd8ed1ab_0    conda-forge
h5py                      3.6.0           nompi_py38hfbb2109_100    conda-forge
hdf4                      4.2.15               h10796ff_3    conda-forge
hdf5                      1.12.1          nompi_h4df4325_104    conda-forge
heapdict                  1.0.1                      py_0    conda-forge
icu                       69.1                 h9c3ff4c_0    conda-forge
idna                      3.3                pyhd8ed1ab_0    conda-forge
importlib-metadata        4.11.3           py38h578d9bd_1    conda-forge
importlib_metadata        4.11.3               hd8ed1ab_1    conda-forge
importlib_resources       5.7.1              pyhd8ed1ab_0    conda-forge
iniconfig                 1.1.1              pyh9f0ad1d_0    conda-forge
ipykernel                 6.13.0           py38h7f3c49e_0    conda-forge
ipython                   8.2.0            py38h578d9bd_0    conda-forge
ipython_genutils          0.2.0                      py_1    conda-forge
itsdangerous              2.1.2              pyhd8ed1ab_0    conda-forge
jasper                    2.0.33               ha77e612_0    conda-forge
jbig                      2.1               h7f98852_2003    conda-forge
jdcal                     1.4.1                      py_0    conda-forge
jedi                      0.18.1           py38h578d9bd_1    conda-forge
jinja2                    3.1.1              pyhd8ed1ab_0    conda-forge
joblib                    1.0.1              pyhd8ed1ab_0    conda-forge
jpeg                      9e                   h166bdaf_1    conda-forge
json-c                    0.16                 hc379101_0    conda-forge
json5                     0.9.6              pyhd3eb1b0_0  
jsonschema                4.4.0              pyhd8ed1ab_0    conda-forge
jupyter-packaging         0.12.0             pyhd8ed1ab_0    conda-forge
jupyter_client            7.2.2              pyhd8ed1ab_1    conda-forge
jupyter_core              4.9.2            py38h578d9bd_0    conda-forge
jupyter_server            1.16.0             pyhd8ed1ab_1    conda-forge
jupyterlab                3.0.14             pyhd8ed1ab_0    conda-forge
jupyterlab-drawio         0.8.0                    pypi_0    pypi
jupyterlab_pygments       0.2.2              pyhd8ed1ab_0    conda-forge
jupyterlab_server         2.13.0             pyhd8ed1ab_1    conda-forge
kealib                    1.4.14               h87e4c3c_3    conda-forge
kernel-headers_linux-64   2.6.32              he073ed8_15    conda-forge
keyutils                  1.6.1                h166bdaf_0    conda-forge
kiwisolver                1.4.2            py38h43d8883_1    conda-forge
krb5                      1.19.3               h08a2579_0    conda-forge
lcms2                     2.12                 hddcbb42_0    conda-forge
ld_impl_linux-64          2.36.1               hea4e1c9_2    conda-forge
lerc                      3.0                  h9c3ff4c_0    conda-forge
libaec                    1.0.6                h9c3ff4c_0    conda-forge
libblas                   3.9.0           14_linux64_openblas    conda-forge
libbrotlicommon           1.0.9                h166bdaf_7    conda-forge
libbrotlidec              1.0.9                h166bdaf_7    conda-forge
libbrotlienc              1.0.9                h166bdaf_7    conda-forge
libcblas                  3.9.0           14_linux64_openblas    conda-forge
libclang                  13.0.1          default_hc23dcda_0    conda-forge
libcurl                   7.82.0               h2283fc2_0    conda-forge
libdap4                   3.20.6               hd7c4107_2    conda-forge
libdeflate                1.10                 h7f98852_0    conda-forge
libedit                   3.1.20210910         h7f8727e_0  
libev                     4.33                 h516909a_1    conda-forge
libevent                  2.1.10               h28343ad_4    conda-forge
libffi                    3.4.2                h7f98852_5    conda-forge
libgcc-devel_linux-64     11.2.0              h0952999_15    conda-forge
libgcc-ng                 11.2.0              h1d223b6_15    conda-forge
libgdal                   3.4.2                h0e87c58_6    conda-forge
libgfortran-ng            11.2.0              h69a702a_15    conda-forge
libgfortran5              11.2.0              h5c6108e_15    conda-forge
libglib                   2.70.2               h174f98d_4    conda-forge
libglu                    9.0.0             he1b5a44_1001    conda-forge
libgomp                   11.2.0              h1d223b6_15    conda-forge
libiconv                  1.16                 h516909a_0    conda-forge
libkml                    1.3.0             h238a007_1014    conda-forge
liblapack                 3.9.0           14_linux64_openblas    conda-forge
libllvm10                 10.0.1               he513fc3_3    conda-forge
libllvm13                 13.0.1               hf817b99_2    conda-forge
libmagic                  5.39                 h27826a3_0    conda-forge
libnetcdf                 4.8.1           nompi_hb3fd0d9_101    conda-forge
libnghttp2                1.47.0               he49606f_0    conda-forge
libnsl                    2.0.0                h7f98852_0    conda-forge
libogg                    1.3.5                h27cfd23_1  
libopenblas               0.3.20          pthreads_h78a6416_0    conda-forge
libopus                   1.3.1                h7f98852_1    conda-forge
libpng                    1.6.37               h21135ba_2    conda-forge
libpq                     14.2                 h676c864_0    conda-forge
librttopo                 1.1.0                hf69c175_9    conda-forge
libsanitizer              11.2.0              he4da1e4_15    conda-forge
libsodium                 1.0.18               h36c2ea0_1    conda-forge
libspatialindex           1.9.3                h9c3ff4c_4    conda-forge
libspatialite             5.0.1               ha867d66_15    conda-forge
libssh2                   1.10.0               ha35d2d1_2    conda-forge
libstdcxx-ng              11.2.0              he4da1e4_15    conda-forge
libtiff                   4.3.0                h542a066_3    conda-forge
libuuid                   2.32.1            h7f98852_1000    conda-forge
libuv                     1.43.0               h7f98852_0    conda-forge
libvorbis                 1.3.7                h9c3ff4c_0    conda-forge
libwebp                   1.2.2                h3452ae3_0    conda-forge
libwebp-base              1.2.2                h7f98852_1    conda-forge
libxcb                    1.13              h7f98852_1004    conda-forge
libxkbcommon              1.0.3                he3ba5ed_0    conda-forge
libxml2                   2.9.12               h885dcf4_1    conda-forge
libxslt                   1.1.33               h0ef7038_3    conda-forge
libzip                    1.8.0                h1c5bbd1_1    conda-forge
libzlib                   1.2.11            h166bdaf_1014    conda-forge
line_profiler             3.3.0            py38h1fd1430_0    conda-forge
llvmlite                  0.36.0           py38h4630a5e_0    conda-forge
locket                    0.2.1            py38h06a4308_2  
lxml                      4.8.0            py38h0a891b7_2    conda-forge
lz4                       4.0.0            py38h1bf946c_1    conda-forge
lz4-c                     1.9.3                h9c3ff4c_1    conda-forge
mapclassify               2.4.3              pyhd8ed1ab_0    conda-forge
markupsafe                2.1.1            py38h0a891b7_1    conda-forge
matplotlib                3.5.1            py38h578d9bd_0    conda-forge
matplotlib-base           3.5.1            py38hf4fb855_0    conda-forge
matplotlib-inline         0.1.3              pyhd8ed1ab_0    conda-forge
mccabe                    0.6.1                      py_1    conda-forge
memoization               0.3.2              pyhd8ed1ab_0    conda-forge
mistune                   0.8.4           py38h497a2fe_1005    conda-forge
more-itertools            8.12.0             pyhd8ed1ab_0    conda-forge
msgpack-python            1.0.3            py38h43d8883_1    conda-forge
multipledispatch          0.6.0                      py_0    conda-forge
munch                     2.5.0                      py_0    conda-forge
munkres                   1.1.4              pyh9f0ad1d_0    conda-forge
mypy_extensions           0.4.3            py38h578d9bd_5    conda-forge
mysql-common              8.0.28               h26416b9_4    conda-forge
mysql-libs                8.0.28               hbc51c84_4    conda-forge
nb_black                  1.0.7                      py_0    conda-forge
nbclassic                 0.3.7              pyhd8ed1ab_0    conda-forge
nbclient                  0.6.0              pyhd8ed1ab_0    conda-forge
nbconvert                 6.5.0              pyhd8ed1ab_0    conda-forge
nbconvert-core            6.5.0              pyhd8ed1ab_0    conda-forge
nbconvert-pandoc          6.5.0              pyhd8ed1ab_0    conda-forge
nbformat                  5.3.0              pyhd8ed1ab_0    conda-forge
ncurses                   6.3                  h27087fc_1    conda-forge
nest-asyncio              1.5.5              pyhd8ed1ab_0    conda-forge
netcdf4                   1.5.8           nompi_py38h2823cc8_101    conda-forge
networkx                  2.6.2              pyhd3eb1b0_0  
nodejs                    17.8.0               hfba9c51_0    conda-forge
notebook                  6.4.11             pyha770c72_0    conda-forge
notebook-shim             0.1.0              pyhd8ed1ab_0    conda-forge
nspr                      4.33                 h295c915_0  
nss                       3.77                 h2350873_0    conda-forge
numba                     0.53.1           py38h0e12cce_0    conda-forge
numpy                     1.22.3           py38h1d589f8_2    conda-forge
odfpy                     1.4.1                      py_0    conda-forge
openjpeg                  2.4.0                hb52868f_1    conda-forge
openpyxl                  3.0.7              pyhd8ed1ab_0    conda-forge
openssl                   3.0.3                h166bdaf_0    conda-forge
outcome                   1.1.0              pyhd8ed1ab_0    conda-forge
owslib                    0.24.1             pyhd8ed1ab_0    conda-forge
packaging                 21.3               pyhd8ed1ab_0    conda-forge
pandas                    1.4.2            py38h47df419_1    conda-forge
pandoc                    2.18                 ha770c72_0    conda-forge
pandocfilters             1.5.0              pyhd8ed1ab_0    conda-forge
param                     1.12.1             pyh6c4a22f_0    conda-forge
parcels                   2.3.0            py38h578d9bd_2    conda-forge
parso                     0.8.3              pyhd8ed1ab_0    conda-forge
partd                     1.2.0              pyhd8ed1ab_0    conda-forge
pathspec                  0.9.0              pyhd8ed1ab_0    conda-forge
patsy                     0.5.2              pyhd8ed1ab_0    conda-forge
pcre                      8.45                 h9c3ff4c_0    conda-forge
pendulum                  2.1.2              pyhd8ed1ab_1    conda-forge
pexpect                   4.8.0              pyh9f0ad1d_2    conda-forge
pickleshare               0.7.5                   py_1003    conda-forge
pillow                    9.1.0            py38h0ee0e06_2    conda-forge
pip                       22.0.4             pyhd8ed1ab_0    conda-forge
pixman                    0.40.0               h36c2ea0_0    conda-forge
platformdirs              2.5.1              pyhd8ed1ab_0    conda-forge
pluggy                    0.13.1           py38h578d9bd_4    conda-forge
poppler                   22.01.0              h1434ded_2    conda-forge
poppler-data              0.4.11               hd8ed1ab_0    conda-forge
postgresql                14.2                 hce44dc1_0    conda-forge
progressbar2              4.0.0              pyhd8ed1ab_0    conda-forge
proj                      9.0.0                h93bde94_1    conda-forge
prometheus_client         0.14.1             pyhd8ed1ab_0    conda-forge
prompt-toolkit            3.0.29             pyha770c72_0    conda-forge
psutil                    5.9.0            py38h0a891b7_1    conda-forge
pthread-stubs             0.4               h36c2ea0_1001    conda-forge
ptyprocess                0.7.0              pyhd3deb0d_0    conda-forge
pure_eval                 0.2.2              pyhd8ed1ab_0    conda-forge
py                        1.11.0             pyh6c4a22f_0    conda-forge
pyasn1                    0.4.8                      py_0    conda-forge
pycodestyle               2.7.0              pyhd8ed1ab_0    conda-forge
pycosat                   0.6.3           py38h0a891b7_1010    conda-forge
pycparser                 2.21               pyhd8ed1ab_0    conda-forge
pyct                      0.4.8                    py38_0  
pyepsg                    0.4.0                      py_0    conda-forge
pyflakes                  2.3.1              pyhd8ed1ab_0    conda-forge
pygments                  2.11.2             pyhd8ed1ab_0    conda-forge
pymbolic                  2021.1             pyhd8ed1ab_0    conda-forge
pyopenssl                 22.0.0             pyhd8ed1ab_0    conda-forge
pyparsing                 3.0.8              pyhd8ed1ab_0    conda-forge
pyproj                    3.3.0            py38hbc0797c_2    conda-forge
pyqt                      5.12.3           py38ha8c2ead_4    conda-forge
pyqt5-sip                 4.19.18          py38h709712a_7    conda-forge
pyqtchart                 5.12                     pypi_0    pypi
pyqtwebengine             5.12.1                   pypi_0    pypi
pyrsistent                0.18.1           py38h0a891b7_1    conda-forge
pyshp                     2.2.0              pyhd8ed1ab_0    conda-forge
pysocks                   1.7.1            py38h578d9bd_5    conda-forge
pytest                    6.2.3            py38h578d9bd_0    conda-forge
pytest-datadir            1.3.1                      py_0    conda-forge
pytest-sugar              0.9.4              pyh9f0ad1d_1    conda-forge
python                    3.8.13          ha86cf86_0_cpython    conda-forge
python-dateutil           2.8.2              pyhd8ed1ab_0    conda-forge
python-eccodes            2021.03.0        py38hb5d20a5_1    conda-forge
python-fastjsonschema     2.15.3             pyhd8ed1ab_0    conda-forge
python-magic              0.4.22           py38h578d9bd_1    conda-forge
python-utils              3.1.0              pyhd8ed1ab_0    conda-forge
python_abi                3.8                      2_cp38    conda-forge
pytools                   2022.1.4           pyh8a188c0_0    conda-forge
pytz                      2022.1             pyhd8ed1ab_0    conda-forge
pytzdata                  2020.1             pyh9f0ad1d_0    conda-forge
pywavelets                1.1.1            py38h5c078b8_3    conda-forge
pyyaml                    6.0              py38h0a891b7_4    conda-forge
pyzmq                     22.3.0           py38hfc09fa9_2    conda-forge
qt                        5.12.9               h1304e3e_6    conda-forge
readline                  8.1.2                h7f8727e_1  
requests                  2.27.1             pyhd8ed1ab_0    conda-forge
rsa                       4.8                pyhd8ed1ab_0    conda-forge
rtree                     1.0.0            py38h02d302b_1    conda-forge
ruamel_yaml               0.15.100         py38h27cfd23_0  
scikit-learn              0.24.2           py38hdc147b9_0    conda-forge
scipy                     1.8.0            py38h56a6a73_1    conda-forge
seaborn                   0.11.1               hd8ed1ab_1    conda-forge
seaborn-base              0.11.1             pyhd8ed1ab_1    conda-forge
selenium                  4.1.0              pyhd8ed1ab_0    conda-forge
send2trash                1.8.0              pyhd8ed1ab_0    conda-forge
setuptools                62.1.0           py38h578d9bd_0    conda-forge
shapely                   1.8.0            py38h97f7145_6    conda-forge
singleton-decorator       1.0.0                    pypi_0    pypi
six                       1.16.0             pyh6c4a22f_0    conda-forge
sniffio                   1.2.0            py38h578d9bd_3    conda-forge
sortedcontainers          2.4.0              pyhd8ed1ab_0    conda-forge
soupsieve                 2.3.1              pyhd8ed1ab_0    conda-forge
sqlite                    3.38.2               h4ff8645_0    conda-forge
stack_data                0.2.0              pyhd8ed1ab_0    conda-forge
statsmodels               0.13.2           py38h6c62de6_0    conda-forge
sysroot_linux-64          2.12                he073ed8_15    conda-forge
tblib                     1.7.0              pyhd8ed1ab_0    conda-forge
termcolor                 1.1.0                      py_2    conda-forge
terminado                 0.13.3           py38h578d9bd_1    conda-forge
theme-darcula             3.0.0              pyhd8ed1ab_0    conda-forge
threadpoolctl             3.1.0              pyh8a188c0_0    conda-forge
thredds_crawler           1.5.4                      py_1    conda-forge
tiledb                    2.8.0                h3f4058f_1    conda-forge
tinycss2                  1.1.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
tomlkit                   0.10.1             pyha770c72_0    conda-forge
toolz                     0.11.2             pyhd8ed1ab_0    conda-forge
tornado                   6.1              py38h0a891b7_3    conda-forge
tqdm                      4.64.0             pyhd8ed1ab_0    conda-forge
traitlets                 5.1.1              pyhd8ed1ab_0    conda-forge
trio                      0.20.0           py38h578d9bd_1    conda-forge
trio-websocket            0.9.2              pyhd8ed1ab_0    conda-forge
typed-ast                 1.5.3            py38h0a891b7_0    conda-forge
typing                    3.10.0.0           pyhd8ed1ab_0    conda-forge
typing_extensions         4.2.0              pyha770c72_1    conda-forge
tzcode                    2022a                h166bdaf_0    conda-forge
tzdata                    2022a                h191b570_0    conda-forge
unicodedata2              14.0.0           py38h0a891b7_1    conda-forge
urllib3                   1.26.9             pyhd8ed1ab_0    conda-forge
wcwidth                   0.2.5              pyh9f0ad1d_2    conda-forge
webencodings              0.5.1                      py_1    conda-forge
websocket-client          1.3.2              pyhd8ed1ab_0    conda-forge
werkzeug                  2.1.1              pyhd8ed1ab_0    conda-forge
wheel                     0.37.1             pyhd8ed1ab_0    conda-forge
wsproto                   1.1.0            py38h578d9bd_0    conda-forge
xarray                    2022.3.0           pyhd8ed1ab_0    conda-forge
xerces-c                  3.2.3                h8ce2273_4    conda-forge
xlrd                      2.0.1              pyhd8ed1ab_3    conda-forge
xorg-fixesproto           5.0               h7f98852_1002    conda-forge
xorg-inputproto           2.3.2             h7f98852_1002    conda-forge
xorg-kbproto              1.0.7             h7f98852_1002    conda-forge
xorg-libice               1.0.10               h7f98852_0    conda-forge
xorg-libsm                1.2.3             hd9c2040_1000    conda-forge
xorg-libx11               1.7.2                h7f98852_0    conda-forge
xorg-libxau               1.0.9                h7f98852_0    conda-forge
xorg-libxdmcp             1.1.3                h7f98852_0    conda-forge
xorg-libxext              1.3.4                h7f98852_1    conda-forge
xorg-libxfixes            5.0.3             h7f98852_1004    conda-forge
xorg-libxi                1.7.10               h7f98852_0    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             h7f98852_1002    conda-forge
xorg-xproto               7.0.31            h7f98852_1007    conda-forge
xz                        5.2.5                h516909a_1    conda-forge
yaml                      0.2.5                h7f98852_2    conda-forge
zeromq                    4.3.4                h9c3ff4c_1    conda-forge
zict                      2.1.0              pyhd8ed1ab_0    conda-forge
zipp                      3.8.0              pyhd8ed1ab_0    conda-forge
zlib                      1.2.11            h166bdaf_1014    conda-forge
zstd                      1.5.2                ha95c52a_0    conda-forge
@greglucas
Copy link
Contributor

Seems like a reasonable fix. Care to make a PR with that update?

@axnsantana
Copy link
Contributor Author

Sure, I just create the PR #2050
I could create a test, but for that, I would need to import xarray, which would increase the library dependency.
If you think the new test is still necessary, I will provide it.

@QuLogic QuLogic added this to the 0.21 milestone May 25, 2022
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

3 participants