diff --git a/doc/_static/ci.png b/doc/_static/ci.png index aec900b1fc5..090f466383e 100644 Binary files a/doc/_static/ci.png and b/doc/_static/ci.png differ diff --git a/doc/_static/dataset-diagram.png b/doc/_static/dataset-diagram.png index be9aa8d653c..9ec18f65028 100644 Binary files a/doc/_static/dataset-diagram.png and b/doc/_static/dataset-diagram.png differ diff --git a/doc/_static/logos/Xarray_Icon_Final.png b/doc/_static/logos/Xarray_Icon_Final.png index 6c0bae41829..d5ae1d79e8e 100644 Binary files a/doc/_static/logos/Xarray_Icon_Final.png and b/doc/_static/logos/Xarray_Icon_Final.png differ diff --git a/doc/_static/logos/Xarray_Logo_FullColor_InverseRGB_Final.png b/doc/_static/logos/Xarray_Logo_FullColor_InverseRGB_Final.png index 68701eea116..8942dce382c 100644 Binary files a/doc/_static/logos/Xarray_Logo_FullColor_InverseRGB_Final.png and b/doc/_static/logos/Xarray_Logo_FullColor_InverseRGB_Final.png differ diff --git a/doc/_static/logos/Xarray_Logo_RGB_Final.png b/doc/_static/logos/Xarray_Logo_RGB_Final.png index 823ff8db961..0a07cbb85ca 100644 Binary files a/doc/_static/logos/Xarray_Logo_RGB_Final.png and b/doc/_static/logos/Xarray_Logo_RGB_Final.png differ diff --git a/doc/_static/opendap-prism-tmax.png b/doc/_static/opendap-prism-tmax.png index 7ff778a3d1e..e3f6d70fad0 100644 Binary files a/doc/_static/opendap-prism-tmax.png and b/doc/_static/opendap-prism-tmax.png differ diff --git a/doc/_static/thumbnails/ERA5-GRIB-example.png b/doc/_static/thumbnails/ERA5-GRIB-example.png index 412dd28a6d9..a4c4647b2dd 100644 Binary files a/doc/_static/thumbnails/ERA5-GRIB-example.png and b/doc/_static/thumbnails/ERA5-GRIB-example.png differ diff --git a/doc/_static/thumbnails/ROMS_ocean_model.png b/doc/_static/thumbnails/ROMS_ocean_model.png index 9333335d1ef..953af78c59d 100644 Binary files a/doc/_static/thumbnails/ROMS_ocean_model.png and b/doc/_static/thumbnails/ROMS_ocean_model.png differ diff --git a/doc/_static/thumbnails/area_weighted_temperature.png b/doc/_static/thumbnails/area_weighted_temperature.png index 7d3604d7c2b..f74621b5547 100644 Binary files a/doc/_static/thumbnails/area_weighted_temperature.png and b/doc/_static/thumbnails/area_weighted_temperature.png differ diff --git a/doc/_static/thumbnails/monthly-means.png b/doc/_static/thumbnails/monthly-means.png index da5691848b0..d05e1517833 100644 Binary files a/doc/_static/thumbnails/monthly-means.png and b/doc/_static/thumbnails/monthly-means.png differ diff --git a/doc/_static/thumbnails/multidimensional-coords.png b/doc/_static/thumbnails/multidimensional-coords.png index b0d893d6894..25409b07f7c 100644 Binary files a/doc/_static/thumbnails/multidimensional-coords.png and b/doc/_static/thumbnails/multidimensional-coords.png differ diff --git a/doc/_static/thumbnails/toy-weather-data.png b/doc/_static/thumbnails/toy-weather-data.png index 64ac0a4b021..59f53f037ad 100644 Binary files a/doc/_static/thumbnails/toy-weather-data.png and b/doc/_static/thumbnails/toy-weather-data.png differ diff --git a/doc/_static/thumbnails/visualization_gallery.png b/doc/_static/thumbnails/visualization_gallery.png index 9e6c2436be5..2b6c1248b4d 100644 Binary files a/doc/_static/thumbnails/visualization_gallery.png and b/doc/_static/thumbnails/visualization_gallery.png differ diff --git a/doc/_static/view-docs.png b/doc/_static/view-docs.png index 2e79ff6c291..ec03dddd68d 100644 Binary files a/doc/_static/view-docs.png and b/doc/_static/view-docs.png differ diff --git a/doc/examples/monthly_means_output.png b/doc/examples/monthly_means_output.png index 0f391a502b2..a2b3afb916e 100644 Binary files a/doc/examples/monthly_means_output.png and b/doc/examples/monthly_means_output.png differ diff --git a/xarray/core/variable.py b/xarray/core/variable.py index dccfead123f..ed7b9f5511d 100644 --- a/xarray/core/variable.py +++ b/xarray/core/variable.py @@ -46,6 +46,7 @@ ) from xarray.namedarray.core import NamedArray, _raise_if_any_duplicate_dimensions from xarray.namedarray.pycompat import integer_types, is_0d_dask_array, to_duck_array +from xarray.namedarray.utils import module_available from xarray.util.deprecation_helpers import _deprecate_positional_args, deprecate_dims NON_NUMPY_SUPPORTED_ARRAY_TYPES = ( @@ -1948,7 +1949,7 @@ def _wrapper(npa, **kwargs): output_core_dims=[["quantile"]], output_dtypes=[np.float64], dask_gufunc_kwargs=dict(output_sizes={"quantile": len(q)}), - dask="parallelized", + dask="allowed" if module_available("dask", "2024.11.0") else "parallelized", kwargs=kwargs, ) diff --git a/xarray/tests/test_variable.py b/xarray/tests/test_variable.py index 9ebd4e4a4d3..0ed47c2b5fe 100644 --- a/xarray/tests/test_variable.py +++ b/xarray/tests/test_variable.py @@ -36,6 +36,7 @@ assert_equal, assert_identical, assert_no_warnings, + has_dask_ge_2024_11_0, has_pandas_3, raise_if_dask_computes, requires_bottleneck, @@ -1871,9 +1872,16 @@ def test_quantile_interpolation_deprecation(self, method) -> None: def test_quantile_chunked_dim_error(self): v = Variable(["x", "y"], self.d).chunk({"x": 2}) - # this checks for ValueError in dask.array.apply_gufunc - with pytest.raises(ValueError, match=r"consists of multiple chunks"): - v.quantile(0.5, dim="x") + if has_dask_ge_2024_11_0: + # Dask rechunks + np.testing.assert_allclose( + v.compute().quantile(0.5, dim="x"), v.quantile(0.5, dim="x") + ) + + else: + # this checks for ValueError in dask.array.apply_gufunc + with pytest.raises(ValueError, match=r"consists of multiple chunks"): + v.quantile(0.5, dim="x") @pytest.mark.parametrize("compute_backend", ["numbagg", None], indirect=True) @pytest.mark.parametrize("q", [-0.1, 1.1, [2], [0.25, 2]])