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

Method device

python/dgl/sparse/sparse_matrix.py:62–70  ·  view source on GitHub ↗

Returns the device the sparse matrix is on. Returns ------- torch.device The device the sparse matrix is on

(self)

Source from the content-addressed store, hash-verified

60
61 @property
62 def device(self) -> torch.device:
63 """Returns the device the sparse matrix is on.
64
65 Returns
66 -------
67 torch.device
68 The device the sparse matrix is on
69 """
70 return self.c_sparse_matrix.device()
71
72 @property
73 def row(self) -> torch.Tensor:

Callers 1

fetchMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected