quantax.nn.ConvSymmetrize#

class quantax.nn.ConvSymmetrize#

Bases: RawInputLayer

Symmetrize the output of a convolutional network by translations.

The input should be a translation-covariant feature map in the original site ordering, reshapeable to (channels, *lattice.shape[1:]). The layer computes the symmetrized wavefunction by

  • averaging over the channels;

  • averaging over positions along the axes without translation symmetry, e.g. open boundaries;

  • keeping one value per translation group element along the translated axes, where positions between two group elements are averaged into one value;

  • combining the remaining values with the characters of the symmetry group through symmetrize.

__init__(symm: Symmetry | None = None)#
Parameters:

symm –

The symmetry used for symmetrization. It can be

  • None (default): Unit translations are imposed along all periodic axes, and outputs are averaged along all open axes. For fully open boundaries, this reduces to the average over all positions.

  • Identity: The layer leaves inputs unchanged.

  • Translation: Translations given by axis-aligned vectors. An entry \(v\) on an axis keeps one output every \(v\) positions as a translation group element. Axes not covered by any vector are averaged.

__call__(x: Array, s: Array) → Array#

The forward pass.

Parameters:
  • x – The output of the previous layer.

  • s – The raw input basis state.