Materialize the graph data on the current device. This method is a no-op if the graph data is already materialized. Returns ------- DGLGraph The graph on the current device.
(self)
| 5756 | return self.to(F.cpu()) |
| 5757 | |
| 5758 | def materialize_data(self): |
| 5759 | """Materialize the graph data on the current device. |
| 5760 | |
| 5761 | This method is a no-op if the graph data is already materialized. |
| 5762 | |
| 5763 | Returns |
| 5764 | ------- |
| 5765 | DGLGraph |
| 5766 | The graph on the current device. |
| 5767 | """ |
| 5768 | for frame in itertools.chain(self._node_frames, self._edge_frames): |
| 5769 | for col in frame._columns.values(): |
| 5770 | col.data # pylint: disable=pointless-statement |
| 5771 | return self |
| 5772 | |
| 5773 | def pin_memory_(self): |
| 5774 | """Pin the graph structure and node/edge data to the page-locked memory for |