MCPcopy
hub / github.com/apache/tvm / _shard_dim_1

Function _shard_dim_1

tests/python/disco/test_loader.py:58–60  ·  view source on GitHub ↗
(src, num_shards, tgt)

Source from the content-addressed store, hash-verified

56
57@register_global_func("tests.disco.shard_dim_1", override=True)
58def _shard_dim_1(src, num_shards, tgt):
59 s_0, s_1 = src.shape
60 tgt.copyfrom(src.numpy().reshape(s_0, num_shards, s_1 // num_shards).transpose(1, 0, 2))
61
62
63@register_global_func("tests.disco.shard_qkv_0", override=True)

Callers

nothing calls this directly

Calls 4

copyfromMethod · 0.80
numpyMethod · 0.80
transposeMethod · 0.45
reshapeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…