netket.observable.VScore#

class netket.observable.VScore[source]#

Bases: AbstractObservable

Observable computing the V-score of a quantum operator \(H\), as defined in Wu et al., arXiv:2302.04919:

\[V_{\mathrm{score}} = \frac{N\,\mathrm{Var}(H)}{(\langle H \rangle - E_\infty)^2} = \frac{N\,(\langle H^2 \rangle - \langle H \rangle^2)} {(\langle H \rangle - E_\infty)^2}.\]

The trace_diagonal parameter is the infinite-temperature reference energy \(E_\infty := \mathrm{Tr}(H) / \dim(\mathcal{H})\) entering the denominator (it is \(0\) for traceless Hamiltonians, e.g. spin models built from Pauli operators).

The prefactor \(N\) is the number of degrees of freedom. By default it is inferred from the Hilbert space:

  • for spin, qubit and bosonic lattice models, N = hilbert.size (number of sites/modes);

  • for fermionic systems (SpinOrbitalFermions), N is the total particle number hilbert.n_fermions.

For composite or exotic Hilbert spaces, or to use a different convention, pass N explicitly.

Inheritance
Inheritance diagram of netket.observable.VScore
Attributes
N#

The number of degrees of freedom normalising the V-score.

hilbert#

The hilbert space associated to this observable.

operator#
operator_squared#
trace_diagonal#