Belle II Software development
|
Public Member Functions | |
def | __init__ (self, nfeat_in_dim, efeat_in_dim, gfeat_in_dim, efeat_hid_dim, efeat_out_dim, num_hid_layers, dropout, normalize=True) |
def | forward (self, src, dest, edge_attr, u, batch) |
Public Attributes | |
nonlin_function | |
Non-linear activation. | |
num_hid_layers | |
Number of hidden layers. | |
dropout_prob | |
Dropout probability. | |
normalize | |
Normalization. | |
lin_in | |
Linear input layer. | |
lins_hid | |
Intermediate linear layers. | |
lin_out | |
Output linear layer. | |
norm | |
Batch normalization. | |
Updates edge features in MetaLayer: .. math:: e_{ij}^{'} = \\phi^{e}(e_{ij}, v_{i}, v_{j}, u), where :math:`\\phi^{e}` is a neural network of the form .. figure:: figs/MLP_structure.png :width: 42em :align: center Args: nfeat_in_dim (int): Node features input dimension (number of node features in input). efeat_in_dim (int): Edge features input dimension (number of edge features in input). gfeat_in_dim (int): Global features input dimension (number of global features in input). efeat_hid_dim (int): Edge features dimension in hidden layers. efeat_out_dim (int): Edge features output dimension. num_hid_layers (int): Number of hidden layers. dropout (float): Dropout rate :math:`r \\in [0,1]`. normalize (str): Type of normalization (batch/layer). :return: Updated edge features tensor. :rtype: `Tensor <https://pytorch.org/docs/stable/tensors.html#torch.Tensor>`_
Definition at line 30 of file geometric_layers.py.
def __init__ | ( | self, | |
nfeat_in_dim, | |||
efeat_in_dim, | |||
gfeat_in_dim, | |||
efeat_hid_dim, | |||
efeat_out_dim, | |||
num_hid_layers, | |||
dropout, | |||
normalize = True |
|||
) |
Initialization.
Definition at line 58 of file geometric_layers.py.
def forward | ( | self, | |
src, | |||
dest, | |||
edge_attr, | |||
u, | |||
batch | |||
) |
Called internally by PyTorch to propagate the input through the network. - src, dest: [E, F_x], where E is the number of edges. - edge_attr: [E, F_e] - u: [B, F_u], where B is the number of graphs. - batch: [E] with max entry B - 1.
Definition at line 103 of file geometric_layers.py.
dropout_prob |
Dropout probability.
Definition at line 79 of file geometric_layers.py.
lin_in |
Linear input layer.
Definition at line 84 of file geometric_layers.py.
lin_out |
Output linear layer.
Definition at line 95 of file geometric_layers.py.
lins_hid |
Intermediate linear layers.
Definition at line 88 of file geometric_layers.py.
nonlin_function |
Non-linear activation.
Definition at line 75 of file geometric_layers.py.
norm |
Batch normalization.
Definition at line 99 of file geometric_layers.py.
normalize |
Normalization.
Definition at line 81 of file geometric_layers.py.
num_hid_layers |
Number of hidden layers.
Definition at line 77 of file geometric_layers.py.