xnn.gnn.fast.megnet.block_function#
- xnn.gnn.fast.megnet.block_function(n_dense, n_conv, residual, act)[source]#
f(e, x, u, *weights, dst, src, batch, edge_batch, per_atom, per_structure_bonds, per_structure_atoms): one MEGNet block with the first layers of the bond and atom updates split.The weights are the dense layers (bond, atom, state;
n_denselayers each, none for the first block) and the update networks (bond, atom, state;n_convlayers each), as (weight, bias) per layer. The counts are clamped(n, 1)columns. Withresidualthe block’s inputs are added to its outputs.