quantax.optimizer.OverlapGrad#

class quantax.optimizer.OverlapGrad#

Overlap gradient source defining \(\bar \epsilon\) from the amplitude ratios with a target state, used for supervised wave function optimization.

__init__(target_state: State, clip: float | None = None)#
Parameters:
  • target_state – The target state to be approximated.

  • clip – The clipping value of the centered amplitude ratios, default to no clipping.

property target_state: State#

The target state to be approximated.

ebar(state: Variational, samples: Samples | Array) Array#

Compute \(\bar \epsilon\) from the normalized amplitude ratios \(\phi_s / \psi_s\) for given samples.

ebar_dense(psi: Array, symm: Symmetry, Ns: int | None = None) Array#

Compute \(\bar \epsilon = \psi - \phi / \left<\psi|\phi\right>\) for the normalized wave function psi given in the full Hilbert space of symm, whose first Ns entries are the physical amplitudes.