qmc/sse: default EPSILON to an ergodic value for sign-problematic models - #98
qmc/sse: default EPSILON to an ergodic value for sign-problematic models#98skilledwolf wants to merge 4 commits into
Conversation
The sse4 worker reads EPSILON (default 0) and floors it to 1e-6
regardless of the Hamiltonian. The per-bond diagonal constant is
c(type) = epsilon + max_diag_me(type), so the vertex carrying the
maximum diagonal matrix element is inserted with weight
c - me = epsilon ~= 1e-6.
On a sign-problematic (frustrated / non-bipartite) Hamiltonian this
makes the diagonal update effectively non-ergodic: the operator-string
sampler freezes, the expansion order <n> is undersampled, and the
simulation reports a confidently wrong, seed-dependent energy with
small error bars. A 3x3 Heisenberg lattice with periodic boundary
conditions gives <H> = -3.39 at beta=1 against the exact thermal
average -2.6525 (checked with two independent exact
diagonalizations). The constructor already warned about exactly this
case ("make sure that EPSILON is ergodic") but proceeded with the
non-ergodic floor.
The SSE energy estimator is invariant to EPSILON (a constant shift of
the diagonal vertex weights), so when EPSILON is unset and the model
is signed, default it to the largest diagonal matrix element. That
gives the maximum-diagonal vertex an O(1) insertion weight and
restores ergodicity, auto-scaling with the model. Sign-free models
keep the previous 1e-6 floor bit-identically (they are ergodic at
EPSILON=0, and a larger shift would only inflate the expansion
order), so existing unfrustrated results are unchanged. An explicit
EPSILON still overrides everything, as before. The warning is
reworded into a note describing the applied default.
Root-caused and fixed in the ALPS modernization fork while chasing
wrong SSE energies on periodic 2-D lattices; instrumentation first
refuted a bond-counting hypothesis and then identified the frozen
diagonal update. Verified there against exact diagonalization on a
periodic 3x3 Heisenberg lattice (SSE reproduces the exact <H> within
error bars after this change, with no EPSILON set) plus unchanged
results on chains and open 2-D/3-D lattices.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Assigning @LodePollet with reviewers @Ooolab and @marcusr2ML . This is the SSE4 code. Technically falls under Lode's umbrella; @LodePollet let us know if you're comfortable with that code, I see it's been authored exclusively by Sergei Isakov. |
|
@egull (AI generated synopsis) Verified locally, independent of the numbers in the PR description. Built both Master (unpatched):
Fix (
This confirms the core claim: the old LGTM from a correctness/repro standpoint. |
|
@marcusr2ML I'd still like @LodePollet to take the lead here. I don't know the sse code well. It all looks good, but we need a human in the loop who's familar with the design decisions that went into this in the first place. |
|
merging in master so we can profit from a cmake.verbose fix that makes the builds pass. |
|
will look into it. |
Ooolab
left a comment
There was a problem hiding this comment.
I don't think we could overcome sign problem by simply changing the constant EPSILON value. I would say if the sign problem is severe the effective number of samples from the simulation is still limited. But I will approve this, since at least something is tuned to check the sign average.
|
Agreed—this does not mitigate the sign problem or increase the effective sample count after sign reweighting. It only prevents the diagonal update from freezing because the maximum-diagonal vertex has an approximately zero insertion weight. |
Problem
The sse4 worker reads
EPSILON(default 0) and floors it to 1e-6 regardless of the Hamiltonian. The per-bond diagonal constant isc(type) = epsilon + max_diag_me(type), so the vertex carrying the maximum diagonal matrix element is inserted with weightc − me = epsilon ≈ 1e-6.On a sign-problematic (frustrated / non-bipartite) Hamiltonian this makes the diagonal update effectively non-ergodic: the operator-string sampler freezes, the expansion order ⟨n⟩ is undersampled, and the simulation reports a confidently wrong, seed-dependent energy with small error bars. The constructor already warns about exactly this case ("make sure that EPSILON is ergodic") but proceeds with the non-ergodic floor.
Fix
The SSE energy estimator is invariant to
EPSILON(a constant shift of the diagonal vertex weights), so whenEPSILONis unset and the model is signed, default it to the largest diagonal matrix element. That gives the maximum-diagonal vertex an O(1) insertion weight and restores ergodicity, auto-scaling with the model.EPSILONstill overrides everything, as before.How to reproduce
Save as
parm(a 3×3 periodic-boundary Heisenberg lattice — "square lattice" inlattices.xmlis periodic — at β=1; no EPSILON set):Exact thermal reference for this lattice at β=1: ⟨H⟩ = −2.6525 (checked with two independent exact diagonalizations).
Chains and open 2-D/3-D (sign-free) lattices produce bit-identical results before/after, since the new default only engages when
is_signed().Provenance
Root-caused in a downstream ALPS modernization fork while chasing wrong SSE energies on periodic 2-D lattices; instrumentation first refuted a bond-counting hypothesis and then identified the frozen diagonal update. Locked there against ED.