MCPcopy Index your code
hub / github.com/dmlc/dgl / test_data_hash

Function test_data_hash

tests/python/common/data/test_data.py:112–124  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

110)
111@unittest.skipIf(dgl.backend.backend_name == "mxnet", reason="Skip MXNet")
112def test_data_hash():
113 class HashTestDataset(data.DGLDataset):
114 def __init__(self, hash_key=()):
115 super(HashTestDataset, self).__init__("hashtest", hash_key=hash_key)
116
117 def _load(self):
118 pass
119
120 a = HashTestDataset((True, 0, "1", (1, 2, 3)))
121 b = HashTestDataset((True, 0, "1", (1, 2, 3)))
122 c = HashTestDataset((True, 0, "1", (1, 2, 4)))
123 assert a.hash == b.hash
124 assert a.hash != c.hash
125
126
127@unittest.skipIf(

Callers 1

test_data.pyFile · 0.85

Calls 1

HashTestDatasetClass · 0.85

Tested by

no test coverage detected