DataArray.clip() of a chunked array returns an assertion error as soon as the argument takes an chunked array. With non-chunked arrays every thing works as intended.
x = xr.DataArray(np.random.uniform(size=[100, 100])).chunk(10)
x.clip(max=x)
Environment:
Output of xr.show_versions()
INSTALLED VERSIONS
commit: None
python: 3.7.9 | packaged by conda-forge | (default, Dec 9 2020, 21:08:20)
[GCC 9.3.0]
python-bits: 64
OS: Linux
OS-release: 5.4.0-60-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8
LOCALE: en_US.UTF-8
libhdf5: 1.10.4
libnetcdf: 4.6.3
xarray: 0.16.2
pandas: 1.2.0
numpy: 1.19.5
scipy: 1.5.0
netCDF4: 1.5.3
pydap: None
h5netcdf: 0.7.4
h5py: 2.10.0
Nio: None
zarr: 2.3.2
cftime: 1.0.4.2
nc_time_axis: None
PseudoNetCDF: None
rasterio: 1.1.0
cfgrib: None
iris: None
bottleneck: 1.2.1
dask: 2020.12.0
distributed: 2020.12.0
matplotlib: 3.1.3
cartopy: 0.18.0
seaborn: 0.11.0
numbagg: None
pint: None
setuptools: 49.2.1.post20200807
pip: 20.2.1
conda: 4.8.3
pytest: 6.0.1
IPython: 7.11.1
sphinx: 3.1.2
DataArray.clip() of a chunked array returns an assertion error as soon as the argument takes an chunked array. With non-chunked arrays every thing works as intended.
Environment:
Output of xr.show_versions()
INSTALLED VERSIONS
commit: None
python: 3.7.9 | packaged by conda-forge | (default, Dec 9 2020, 21:08:20)
[GCC 9.3.0]
python-bits: 64
OS: Linux
OS-release: 5.4.0-60-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8
LOCALE: en_US.UTF-8
libhdf5: 1.10.4
libnetcdf: 4.6.3
xarray: 0.16.2
pandas: 1.2.0
numpy: 1.19.5
scipy: 1.5.0
netCDF4: 1.5.3
pydap: None
h5netcdf: 0.7.4
h5py: 2.10.0
Nio: None
zarr: 2.3.2
cftime: 1.0.4.2
nc_time_axis: None
PseudoNetCDF: None
rasterio: 1.1.0
cfgrib: None
iris: None
bottleneck: 1.2.1
dask: 2020.12.0
distributed: 2020.12.0
matplotlib: 3.1.3
cartopy: 0.18.0
seaborn: 0.11.0
numbagg: None
pint: None
setuptools: 49.2.1.post20200807
pip: 20.2.1
conda: 4.8.3
pytest: 6.0.1
IPython: 7.11.1
sphinx: 3.1.2