netket.models.GCNN#
- netket.models.GCNN(symmetries=None, product_table=None, irreps=None, point_group=None, mode='auto', shape=None, layers=None, features=None, characters=None, parity=None, param_dtype=<class 'numpy.float64'>, complex_output=True, input_mask=None, hidden_mask=None, **kwargs)[source]#
Implements a Group Convolutional Neural Network (G-CNN) that outputs a wavefunction that is invariant over a specified symmetry group.
The G-CNN is described in Cohen et al. and applied to quantum many-body problems in Roth et al. .
The G-CNN alternates convolution operations with pointwise non-linearities. The first layer is symmetrized linear transform given by DenseSymm, while the other layers are G-convolutions given by DenseEquivariant. The hidden layers of the G-CNN are related by the following equation:
\[{\bf f}^{i+1}_h = \Gamma( \sum_h W_{g^{-1} h} {\bf f}^i_h).\]- Parameters:
symmetries β A specification of the symmetry group. Can be given by a
netket.graph.Graph
, anetket.utils.group.PermutationGroup
, or an array[n_symm, n_sites]
specifying the permutations corresponding to symmetry transformations of the lattice.product_table β Product table describing the algebra of the symmetry group. Only needs to be specified if mode=βfftβ and symmetries is specified as an array.
irreps β List of 3D tensors that project onto irreducible representations of the symmetry group. Only needs to be specified if mode=βirrepsβ and symmetries is specified as an array.
point_group β The point group, from which the space group is built. If symmetries is a graph the default point group is overwritten.
mode β string βfft, irreps, matrix, autoβ specifying whether to use a fast fourier transform over the translation group, a fourier transform using the irreducible representations or by constructing the full kernel matrix.
shape β A tuple specifying the dimensions of the translation group.
layers β Number of layers (not including sum layer over output).
features β Number of features in each layer starting from the input. If a single number is given, all layers will have the same number of features.
characters β Array specifying the characters of the desired symmetry representation.
parity β Optional argument with value +/-1 that specifies the eigenvalue with respect to parity (only use on two level systems).
param_dtype β The dtype of the weights.
activation β The nonlinear activation function between hidden layers. Defaults to
netket.nn.activation.reim_selu
.output_activation β The nonlinear activation before the output.
equal_amplitudes β If True forces all basis states to have equal amplitude by setting \(\Re(\psi) = 0\) .
use_bias β If True uses a bias in all layers.
precision β Numerical precision of the computation see
jax.lax.Precision
for details.kernel_init β Initializer for the kernels of all layers. Defaults to
lecun_normal(in_axis=1, out_axis=0)
which guarantees the correct variance of the output. See the documentation offlax.linen.initializers.lecun_normal()
for more information.bias_init β Initializer for the biases of all layers.
complex_output β If True, ensures that the network output is always complex. Necessary when network parameters are real but some characters are negative.
input_mask β Optional array of shape
(n_sites,)
used to restrict the convolutional kernel. Only parameters with mask :math:βne 0β are used. For best performance a boolean mask should be used.hidden_mask β Optional array of shape
(n_symm,)
where(n_symm,) = len(graph.automorphisms())
used to restrict the convolutional kernel. Only parameters with mask :math:βne 0β are used. For best performance a boolean mask should be used.