xnn.common.deploy.domain.DomainPlan#

class xnn.common.deploy.domain.DomainPlan(grid, rank, world, owned, ghosts, ghost_shifts, send_rows, send_counts, recv_counts, edge_index, cell_shifts, pbc, atomic_numbers, total_charge, spin_multiplicity, reference, cell, counts, order, need, skin)[source]#

Bases: object

The atoms one process evaluates, its exchanges and its neighbor list.

Local atoms are the owned atoms followed by the ghosts.

Variables:
  • grid (tuple of int) – Sub-domains along the three axes.

  • world (rank,) – The process (sub-domain) the plan belongs to and the number of processes.

  • owned (Tensor) – Owned atoms (n_owned,), in ascending order.

  • ghosts (Tensor) – Atom behind every ghost (n_ghost,), grouped by owner.

  • ghost_shifts (Tensor or None) – Periodic image of every ghost relative to its owner’s copy (n_ghost, 3); None for a molecule.

  • send_rows (Tensor) – Owned atoms (rows of owned) sent to the other processes, grouped by receiving process.

  • recv_counts (send_counts,) – Rows sent to and received from every process.

  • cell_shifts (edge_index,) – Neighbor list of the local atoms, as in AtomicGraph, out to the cutoff plus the skin; with the one-cutoff shell, only the edges into owned atoms.

  • pbc (Tensor or None) – Periodicity of the local atoms (3,): the periodic axes that are not cut. None when no axis stays periodic.

  • atomic_numbers (Tensor) – Atomic numbers of every atom of the structure (N,).

  • spin_multiplicity (total_charge,) – Of the structure, as in its graph.

  • reference (Tensor) – Positions of the owned atoms when the plan was built (n_owned, 3), float64: fractional and wrapped into the cell for a periodic structure, Cartesian for a molecule.

  • cell (Tensor or None) – The cell when the plan was built (3, 3), float64; None for a molecule.

  • counts (list of int) – Owned atoms of every process.

  • order (Tensor) – The owned atoms of every process, process by process (N,).

  • need (float) – Thickness of the ghost shell the model needs (one cutoff or the receptive field).

  • skin (float) – Thickness added to the shell and the neighbor list.

Parameters:
property n_owned: int#

Number of owned atoms (the first n_owned local atoms).

Type:

int

property n_ghost: int#

Number of ghosts.

Type:

int

property n_local: int#

Number of local atoms (owned and ghosts).

Type:

int

property n_atoms: int#

Number of atoms of the structure.

Type:

int

property index: Tensor#

Atom behind every local atom (n_local,).

Type:

Tensor