MCPcopy Create free account
hub / github.com/pydata/xarray / test_xarray_handles_dask

Function test_xarray_handles_dask

xarray/tests/test_ufuncs.py:134–140  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

132
133
134def test_xarray_handles_dask():
135 da = pytest.importorskip("dask.array")
136 x = xr.DataArray(np.ones((2, 2)), dims=["x", "y"])
137 y = da.ones((2, 2), chunks=(2, 2))
138 result = np.add(x, y)
139 assert result.chunks == ((2,), (2,))
140 assert isinstance(result, xr.DataArray)
141
142
143def test_dask_defers_to_xarray():

Callers

nothing calls this directly

Calls 1

addMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…