MCPcopy
hub / github.com/pydata/xarray / test_CFMaskCoder_decode_dask

Function test_CFMaskCoder_decode_dask

xarray/tests/test_coding.py:77–83  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

75
76@requires_dask
77def test_CFMaskCoder_decode_dask() -> None:
78 original = xr.Variable(("x",), [0, -1, 1], {"_FillValue": -1}).chunk()
79 expected = xr.Variable(("x",), [0, np.nan, 1])
80 coder = variables.CFMaskCoder()
81 encoded = coder.decode(original)
82 assert isinstance(encoded.data, da.Array)
83 assert_identical(expected, encoded)
84
85
86# TODO(shoyer): port other fill-value tests

Callers

nothing calls this directly

Calls 3

decodeMethod · 0.95
assert_identicalFunction · 0.90
chunkMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…