MCPcopy
hub / github.com/dmlc/dgl / test_forking_pickler

Function test_forking_pickler

tests/python/common/test_heterograph.py:3621–3632  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3619 dgl.backend.backend_name == "mxnet", reason="MXNet doesn't support spawning"
3620)
3621def test_forking_pickler():
3622 ctx = mp.get_context("spawn")
3623 g = dgl.graph(([0, 1, 2], [1, 2, 3]))
3624 g.create_formats_()
3625 q = ctx.Queue(1)
3626 proc = ctx.Process(target=_test_forking_pickler_entry, args=(g, q))
3627 proc.start()
3628 fmt = q.get()["created"]
3629 proc.join()
3630 assert "coo" in fmt
3631 assert "csr" in fmt
3632 assert "csc" in fmt
3633
3634
3635if __name__ == "__main__":

Callers

nothing calls this directly

Calls 5

startMethod · 0.80
graphMethod · 0.45
create_formats_Method · 0.45
getMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected