MCPcopy Create free account
hub / github.com/dask/dask / test_h5py_tokenize

Function test_h5py_tokenize

dask/array/tests/test_array_core.py:3598–3611  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3596
3597
3598def test_h5py_tokenize():
3599 h5py = pytest.importorskip("h5py")
3600 with tmpfile("hdf5") as fn1:
3601 with tmpfile("hdf5") as fn2:
3602 f = h5py.File(fn1, mode="a")
3603 g = h5py.File(fn2, mode="a")
3604
3605 f["x"] = np.arange(10).astype(float)
3606 g["x"] = np.ones(10).astype(float)
3607
3608 x1 = f["x"]
3609 x2 = g["x"]
3610
3611 assert tokenize(x1) != tokenize(x2)
3612
3613
3614def test_map_blocks_with_changed_dimension():

Callers

nothing calls this directly

Calls 5

tmpfileFunction · 0.90
tokenizeFunction · 0.50
astypeMethod · 0.45
arangeMethod · 0.45
onesMethod · 0.45

Tested by

no test coverage detected