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

Class HeteroNodeView

python/dgl/distributed/dist_graph.py:340–350  ·  view source on GitHub ↗

A NodeView class to act as G.nodes for a DistGraph.

Source from the content-addressed store, hash-verified

338
339
340class HeteroNodeView(object):
341 """A NodeView class to act as G.nodes for a DistGraph."""
342
343 __slots__ = ["_graph"]
344
345 def __init__(self, graph):
346 self._graph = graph
347
348 def __getitem__(self, key):
349 assert isinstance(key, str)
350 return NodeSpace(data=NodeDataView(self._graph, key))
351
352
353class HeteroEdgeView(object):

Callers 1

nodesMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected