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

Method asbits

python/dgl/graph_index.py:999–1014  ·  view source on GitHub ↗

Transform the graph to a new one with the given number of bits storage. NOTE: this method only works for immutable graph index Parameters ---------- bits : int The number of integer bits (32 or 64) Returns ------- GraphIndex

(self, bits)

Source from the content-addressed store, hash-verified

997 return 32
998
999 def asbits(self, bits):
1000 """Transform the graph to a new one with the given number of bits storage.
1001
1002 NOTE: this method only works for immutable graph index
1003
1004 Parameters
1005 ----------
1006 bits : int
1007 The number of integer bits (32 or 64)
1008
1009 Returns
1010 -------
1011 GraphIndex
1012 The graph index stored using the given number of bits.
1013 """
1014 return _CAPI_DGLImmutableGraphAsNumBits(self, int(bits))
1015
1016
1017@register_object("graph.Subgraph")

Callers 2

get_immutable_gidxMethod · 0.45
astypeMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected