xnn.gnn.models.gemnet.triplets#

xnn.gnn.models.gemnet.triplets(edge_index, num_nodes)[source]#

The triplets c -> a <- b of one-hop message passing (b != c).

Every edge c -> a is paired with every other edge b -> a into the same atom; the output is grouped by the edge c -> a.

Parameters:
  • edge_index (Tensor) – Edge index of shape (2, E).

  • num_nodes (int) – Number of atoms.

Returns:

(ca, ba, slot) of shape (T,): the edge being updated, the incoming edge, and the position of the triplet within the group of its edge c -> a.

Return type:

tuple of Tensor