neuralqx.samplers.rules package

class ExactSampler(*args: Any, **kwargs: Any)

Bases: ExactSampler

This class is just a wrapper for the netket.sampler.ExactSampler class

class U1GaugeSampler(*args: Any, **kwargs: Any)

Bases: MetropolisRule

This class implements a U(1) gauge sampler which samples states from the Hilbert space based on a specified gauge fixing.

The proposed states are ones which lie in the neighborhood of the input states. This is done by flipping one of the free edges’ quantum numbers and reimposing the gauge fixing on the slave edges.

class U1InvariantPlaquetteSampler(*args: Any, **kwargs: Any)

Bases: MetropolisRule

This class implements a U(1) gauge sampler which samples states from the Hilbert space based on a specified gauge fixing.

The proposed states are ones which lie in the neighborhood of the input states. This is done by flipping one of the free edges’ quantum numbers and reimposing the gauge fixing on the slave edges.

class RandomU1GaugeSampler(*args: Any, **kwargs: Any)

Bases: MetropolisRule

This class implements a U(1) gauge sampler which samples states from the Hilbert space based on a specified gauge fixing. The proposed states are essentially random gauge invariant states

class MetropolisKLocalRule(*args: Any, **kwargs: Any) P

Bases: MetropolisRule

class MuSampler(*args: Any, **kwargs: Any)

Bases: MetropolisRule

A sampler which is specific to the spherical model. It operates under the guide that the volume on the internal vertices of the half ladder graph are non-zero. This is done by sampling states where the quantum numbers associated to the mu-edges is never allowed to be zero.

class WeightedSamplerRule(probabilities, rules)

Bases: MetropolisRule

A Metropolis sampling rule that can be used to combine different rules acting on different subspaces of the same tensor-hilbert space.

MultiHamiltonianRule(operators, p_ops=None, *, choose_per_chain=False)

Construct a multi-operator Hamiltonian rule, dispatching to JAX/Numba.

Parameters:
  • operators (Sequence[DiscreteOperatorT | DiscreteJaxOperator]) – sequence of operators. Either all JAX-compatible operators (DiscreteJaxOperator, including ComputationalJaxOperator) or all classic CPU `DiscreteOperator`s

  • p_ops (np.ndarray | jnp.ndarray | None) – optional probabilities for operator selection (uniform if None)

  • choose_per_chain (bool) – draw an operator per chain (True) or per sweep/batch (False)

Return type:

MetropolisRule

class U1GaugeSamplerNonzero(*args: Any, **kwargs: Any)

Bases: MetropolisRule

This class implements a U(1) gauge sampler which samples states from the Hilbert space based on a specified gauge fixing.

The proposed states are ones which lie in the neighborhood of the input states. This is done by flipping one of the free edges’ quantum numbers and reimposing the gauge fixing on the slave edges.