The existing reads_diversity_count study maps the CUDA-SA winnability frontier on
random Ising instances with ternary fields (h∈{−1,0,+1}, J∈{−1,+1}). We want
to rerun the same experiment on the zero-field / J-only problem class (all
h_i=0) to isolate how the coupling structure alone drives the count (k),
diversity (D), and num_reads gates — and to compare the two classes.
Exploration surfaced two things that would silently corrupt a naive rerun, plus a gate inconsistency:
- The energy band shifts. With
h=0the field term vanishes, moving the ground-state energy by ~+474 (≈3.2%,shared/energy_utils.pyexpected_solution_energy/calc_energy_range). The−14635…−15020ladder is the wrong band forh=0and must be re-derived. - Z2 (spin-inversion) symmetry.
E(s)=E(−s)exactly whenh=0, so every solution has an equal-energy twin. The diversity metric already uses a flip-invariant distance (min(hamming, N−hamming),shared/quantum_proof_of_work.py:403), but the count gate (n_unique_below_threshold) dedups raw spin rows (_unique_rows,compute_solution_metaat:330) and would double-count twins.
Decisions locked (with user):
- Count gate → flip-invariant (gauge-canonicalize twins; consistent with diversity).
- Target ladder → matched difficulty (re-derive
h=0energies at the same difficulty rungs; reuse each rung's original adapt params). - Sequencing → calibrate + pilot first (1–2 SA rungs) before the full sweep.
- Cleanups to fold in: multi-seed floor error bars; pool/dedupe boundary re-runs;
standardize
m+ fill the(target, reads)grid.
The new h=0 dataset is built to the clean spec from the start (uniform m, full
grid, ≥3 seeds at the floor, flip-invariant count). The existing h≠0 dataset gets
the free post-processing cleanup (pooling) now; the expensive h≠0 backfills are
listed as optional operator GPU tasks.
All GPU runs execute on the CUDA box (operator) — this Mac can't run CUDA. My deliverable is the code + commands; consolidation/analysis run on CPU afterward.
All changes are additive / opt-in — no consensus or default-behavior change.
generate_ising_model_from_nonce already accepts allowed_h, so this is plumbing.
1a. Thread an h-spec through the feeder (zero field is allowed_h=AllowedValueSet((0,))):
shared/ising_feeder.py— addallowed_h=NonetoRandomIsingFeeder.__init__and to_generate_one_model(:60); pass it to the poolsubmit(...)and intogenerate_ising_model_from_nonce(nonce, nodes, edges, allowed_h=allowed_h)(:76).AllowedValueSetis picklable, so it crosses theProcessPoolExecutorcleanly.test_results/cuda_tts_test/tools/cuda_tts_canary.py— add--h-spec(default"-1,0,1";"0"⇒ zero field), parse toAllowedValueSet, pass to the feeder (_run_target,:524). Recordh_specin each cell summary JSON so the dataset is self-describing.
1b. Flip-invariant count gate (opt-in) — shared/quantum_proof_of_work.py:
- Add a gauge-canonicalization helper (flip each spin row to a fixed convention, e.g.
anchor qubit
= +1, deterministic tie-break) and agauge_fix: bool = Falseparam tocompute_solution_meta(:330). WhenTrue, canonicalizesamplesrows before_unique_rows, so twins collapse →n_unique_*becomes flip-invariant. DefaultFalse⇒ zero change to chain/production callers. Diversity is unaffected (already flip-invariant). - Canary threads
gauge_fix=Trueinto itscompute_solution_metacall when--h-spec 0(auto) or--gauge-fix-count. - Verify on existing
h≠0data that raw ≈ flip-invariant (twins negligible ath≠0), so the cross-class comparison is valid even though theh≠0set used raw.
New script under test_results/reads_diversity_count_h0/. Reuses
shared/energy_utils (calc_energy_range, energy_to_difficulty) and the existing
dataset.json:
- For each original rung
E_old, compute its difficultydon theh≠0curve. - Map
d → E_newon theh=0band (calc_energy_range(h_values=(0,))); expectE_new ≈ E_old + 474, curve-accurate. - Pull each rung's
num_sweepsand reads-grid fromdataset.json(so theh=0run reuses the original per-rung compute — noadapt_parameterschange needed). - Emit
h0_ladder.json:[{E_h0, difficulty, num_sweeps, reads_grid, seeds}].
- Pilot run at 1–2 rungs (one mid-band, one near-frontier), SA,
--h-spec 0,m=10000, pinned params fromh0_ladder.json. - Validate before committing the full sweep: (a) achieved
best_energydistribution lands where the matched-difficulty ladder predicts (else recalibrate the band empirically); (b) flip-invariant vs rawn_uniquegap confirms the twin effect; (c) yields are in a sane range. Adjusth0_ladder.jsonif the analytic band is off.
Drive via the existing runner/shell scripts pointed at a new root
test_results/reads_diversity_count_h0/data/, with --h-spec 0 and pinned params:
- Reads sweeps (
design=reads_sweep) at every rung —m=10000uniform, full1,2,4,…,adaptgrid, including the fine-region targets that were adapt-only before (grid-fill cleanup). - Adapt frontier (
design=adapt_only) for any rung not reads-swept. - Multi-seed at the floor: ≥3 seeds at the deep targets, output namespaced by
seed (
…/e<E>/r<reads>/s<seed>/), for tail error bars.
Runner change: add --params-config h0_ladder.json (skip adapt_parameters, use the
table) and --seeds to reads_sweep_run.py. Reuse run_reads_sweep.sh /
run_cutoff_sweep.sh via OUT_ROOT, TARGETS, M env overrides + the new flags.
Rough cost: uniform m=10k (band was 5k) + multi-seed floor + grid-fill push this
above the ~155 GPU-h original; the pilot refines the estimate.
consolidate.py (extend; serves both datasets):
- Add
--data-root/--outso it buildsdataset_h0.json+dataset_adapt_h0.json. - Add pooling: merge cells with identical
(E, num_reads, num_sweeps, mode, h_spec)across regions and seeds into combined stats (sum models, recomputeC/qbar/best_energy_minover the union; provenance becomes a list). This delivers the multi-seed aggregation (h=0) and the boundary-re-run pooling (h≠0: −15000 ×3, −15010 ×2, −14900 ×2) in one mechanism. - Record
h_specper cell. - Note: pooling re-fits the model at
−14900(band 5k + anchor 10k → 15k), sodataset_adapt.jsonno longer byte-matchesmeasured_yield.json— expected. Re-runyield_model.py; constants should move only within noise (flag any delta).
Analysis + Notion: run the analysis scripts on the h=0 dataset, then produce an
h=0 vs h≠0 comparison — do the 8 results hold? how far does the frontier shift?
how does flip-invariant counting change the k-gate? New Notion page (sibling in the
D-Wave data source) cross-linked to the existing one, same [IMAGE:]-placeholder
convention (Notion MCP can't upload binaries).
| cleanup | h=0 (new) | h≠0 (existing) |
|---|---|---|
| flip-invariant count | built in (Part 1b) | raw kept; verify raw≈flip-inv |
| multi-seed floor | built in (Part 4) | optional operator GPU backfill |
| pool/dedupe re-runs | via pooling (Part 5) | done now (post-processing) |
| standardize m=10k + fill grid | built in (Part 4) | optional operator GPU backfill |
These cost ~no GPU and make the dataset more auditable; not in the four you picked, flagged for a quick yes/no:
- Record per-cell provenance: the
--seed,h_spec,gitcommit, and topology id in each cell summary + carried intodataset.json. Makes every number reproducible from the file alone. - Keep raw
n_uniqueas a diagnostic column alongside the flip-invariant gate value (gate stays flip-invariant per your decision). Theraw/flip-invratio then directly quantifies the Z2-twin effect per cell — a free, interesting measurement rather than a discarded one. - Determinism check: re-run one cell twice at the same seed and assert bit-identical attempts, confirming the canary's reproducibility claim before the big spend.
- One high-m validation rung: a single near-frontier target at
m≈50kto pin the 1-in-10k tail (frontier / deepest-reach) tighter than the multi-seed 10k cells.
- Unit:
h=0feeder producesall(h_i==0)and unchangedJ; default path still ternary (a quickgenerate_ising_model_from_noncecheck).compute_solution_metawithgauge_fix=Truecollapses a hand-builts/−spair ton_unique=1; defaultFalseunchanged. - No-regression: existing tests for
quantum_proof_of_work/ising_feederpass (pytest shared/ -k "ising or proof or feeder"). - Pilot gate: achieved energies match the matched-difficulty ladder (Part 3).
- Consolidate:
dataset_h0.jsoncell counts match the launched grid; pooledh≠0−15000shows summedm(25k);yield_model.pyre-fit constants logged. - Comparison sanity: at matched difficulty,
h=0flip-invariantk-yield andD-survival are reported beside theh≠0numbers.
- No consensus/default change —
allowed_halready exists;gauge_fixdefaultsFalse; feeder/canary changes are additive. Chain validation path untouched. - Operator runs all CUDA (pilot + full); provide commands, don't execute GPU here.
shared/+ canary edits land on a feature branch (feat/h0-field-sweep) → MR; thetest_results/reads_diversity_count_h0/tree is local/gitignored like its sibling.
The Phase A/B work optimizes TTS: it finds the (num_reads, num_sweeps) policy and the frontier map, stopping compute as soon as a sweeps-doubling stops paying (early-stop rule: yield ratio < 2 with ≥20 wins in the prior rung). It deliberately does NOT articulate the full improve-then-degrade response per target. That fuller study is this phase, run only after the TTS policy ships:
- Goal: the full response surface
yield(E, R, S)and TTS iso-surfaces over E ∈ [−14430, −14560], R ∈ {32…256}, S ∈ {1024 … knee+1 octave}, h=0; one ternary anchor slice (e.g. −14900/−14950 × {1×, 2×}) for cross-regime shape comparison. - Reuse: every Phase A/B cell conforms to the Phase C conventions and slots into
the grid as-is — pinned (R, S) per cell, recorded seed, per-cell out-dirs
(
phaseA_e<E>_r<R>_s<S>_seed<seed>/), self-describing summaries (h_spec/gauge_fix/c_range/sweep_mult fields), new 4577-node topology only. Phase C is gap-filling, not a rerun: design the grid, subtract cells already on disk (including early-stopped ladder rungs left unmeasured), run the difference. - Allocation: fill remaining cells by information gain per GPU-hour (the knee/frontier neighborhoods first; deep 0-win regions get Wilson upper bounds at modest m, not precision).
- Analysis: joint surface fit (the analyze_h0_opt.py machinery generalizes: per-read reach q(E,S) × count-gate mixture link), published with per-cell raw data so the fit is reproducible; documents where and why TTS degrades past the knee.