nodeflow.rst 1.68 KB
Newer Older
Da Zheng's avatar
Da Zheng committed
1
2
.. _apinodeflow:

3
4
dgl.nodeflow
==============
Da Zheng's avatar
Da Zheng committed
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80

.. currentmodule:: dgl
.. autoclass:: NodeFlow

Querying graph structure
------------------------

.. autosummary::
    :toctree: ../../generated/

    NodeFlow.num_layers
    NodeFlow.num_blocks
    NodeFlow.layer_size
    NodeFlow.block_size
    NodeFlow.layer_in_degree
    NodeFlow.layer_out_degree
    NodeFlow.layer_nid
    NodeFlow.layer_parent_nid
    NodeFlow.block_eid
    NodeFlow.block_parent_eid
    NodeFlow.block_edges

Converting to other format
-------------------------------

.. autosummary::
    :toctree: ../../generated/

    NodeFlow.block_adjacency_matrix
    NodeFlow.block_incidence_matrix

Using Node/edge features
------------------------

.. autosummary::
    :toctree: ../../generated/

    NodeFlow.layers
    NodeFlow.blocks
    NodeFlow.set_n_initializer
    NodeFlow.set_e_initializer
    NodeFlow.node_attr_schemes
    NodeFlow.edge_attr_schemes

Mapping between NodeFlow and parent graph
-----------------------------------------
.. autosummary::
    :toctree: ../../generated/

    NodeFlow.map_to_parent_nid
    NodeFlow.map_to_parent_eid
    NodeFlow.map_from_parent_nid


Synchronize features between NodeFlow and parent graph
------------------------------------------------------
.. autosummary::
    :toctree: ../../generated/

    NodeFlow.copy_from_parent
    NodeFlow.copy_to_parent

Computing with NodeFlow
-----------------------

.. autosummary::
    :toctree: ../../generated/

    NodeFlow.register_message_func
    NodeFlow.register_reduce_func
    NodeFlow.register_apply_node_func
    NodeFlow.register_apply_edge_func
    NodeFlow.apply_layer
    NodeFlow.apply_block
    NodeFlow.block_compute
    NodeFlow.prop_flow