Skip to content

Valid lower bounds on truncated bidirectional builds; a failed snap step is a failed snap - #80

Merged
Autoplectic merged 2 commits into
mainfrom
truncated-window-bound
Nov 28, 2026
Merged

Autoplectic merged 2 commits into
mainfrom
truncated-window-bound

Conversation

@Autoplectic

@Autoplectic Autoplectic commented Nov 27, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Truncated builds. When the reverse ε-machine is infinite but its mixed states merge within numerical tolerance, the bidirectional machine is a finite truncation. Its generators are verified against the forward machine, so upper bounds hold, but every lower bound generative_model computed on it (excess entropy, support-type, flow and coverage bounds, SCIP's dual on the exact path, the heaviest-term bounds, the restricted global bound) bounds the truncation, not the process, and read "(certified)". On a 2-state ternary process the truncation's generator coverage bound came within 1.5e-6 of the best generator's entropy, 0.9982954, where the future-window bound is 0.9981857. On a truncated build these stages are now skipped, and the lower bound is the larger future-window generator coverage bound at L = 2 and 3 (window_spec, Löhr & Ay 2009), computed first from the forward machine with at most 30% of the budget. minimal_wyner_model reports lower 0 there. Machines whose bidirectional build fails still raise.
  • Classing bidirectional input. resolve_bidirectional classes a bidirectional machine passed in as "truncated" when the reverse ε-machine of its forward machine is infinite (it always reported "finite").
  • Snap. simplex_chains._snap treats a LinAlgError from the Gauss–Newton least-squares step as a failed snap. On a binary 3-state process (n3-t056-d3) the error ended generative_model after 116 s.
  • Deadlines on large reverse sides. With the truncation's lower bounds skipped, later stages run on truncated builds, whose reverse side can have about 100 states, and two of them checked their deadlines too rarely. simplex_chain_search checked between descent rounds, but one wall tangent is a finite-difference Jacobian over every atom coordinate: on a 2-state ternary process with 90 reverse states, generative_model was still running at 1,020 s on a 300 s budget. Atom steps and wall tangents now stop at the deadline. bilevel_search checked once per Powell iteration, which line-searches every logit with a kernel LP per evaluation; with 69 reverse states it ran 163 s past its share. Its objective now raises at the deadline, and the start keeps the best channel it scored.

Tests

  • Fast suite (-m "not slow and not very_slow"): 2935 passed, 9 skipped, before the rebase. After it, test_generative_model.py and the test files changed by Heaviest-term bound after an inconclusive exact path; stop passing dit's _strategy #81 and generator_global_bound: confine the two heaviest weights to a box #82: 94 passed.
  • New: a prebuilt truncation is classed "truncated"; a window lower bound replaces every lower bound of the machine in _bracket_search; a failed least-squares step is a failed snap; and (slow) a truncated ternary build reports the future-window bound below the upper bound, uncertified, within its 60 s budget, with minimal_wyner_model at lower 0.
  • New for the deadlines: the wall tangent stops at its deadline; a 2 s chain search on the 53-state reverse side of an infinite-reverse fixture ends within 20 s (2.1 s; 95 s on main); and with a fake clock, bilevel_search stops inside a Powell iteration at the deadline (6 kernel LPs, against 2,058 on main).

Validation

The 17 survey processes with infinite reverse ε-machines, through generative_model at 300 s, side by side with main at 55b627b. Six of them (n3-t015-d2, n3-t015-d3, n3-t056-d0, n3-t059-d3, n3-t061-d4, n3-t123-d1) raise MixedStateExplosionError in under a second on both trees. The other 11:

Process This branch main
n3-t015-d1 [1.1170387, 1.1214972], 302 s [1.1170206, 1.1214972], 302 s, lower bound from the truncation
n3-t015-d4 [1.3442240, 1.3633209], 304 s [1.0380973, 1.3633209], 491 s
n3-t056-d3 [1.1191498, 1.1284305], 302 s LinAlgError at 116 s
s3-n2-t0022-d0 [0.7154817, 0.7563481], 306 s "certified" at 0.7563481, 11 s
s3-n2-t0022-d1 [0.5580857, 0.5581256], 299 s "certified" at 0.5581256, 3 s
s3-n2-t0022-d2 [0.9981857, 0.9982954], 302 s killed at 1,020 s
s3-n2-t0022-d3 [0.8728953, 0.8939274], 302 s "certified" at 0.8939274, 94 s
s3-n2-t0022-d4 [0.7394723, 0.7480020], 303 s "certified" at 0.7480020, 94 s
s3-n2-t0037-d0 [0.9069289, 0.9235389], 302 s "certified" at 0.9235389, 93 s
s3-n2-t0037-d1 certified at 0.8864390, 144 s certified at 0.8864390, 301 s
s3-n2-t0037-d2 [0.8460402, 0.8460540], 302 s "certified" at 0.8460540, 91 s

On this branch every lower bound is the future-window bound, and every run ends by 306 s. The seven quoted certificates on main rest on lower bounds of the truncation. On s3-n2-t0037-d1 the certificate happens to hold: the window bound at L = 3 is within 4e-8 of the best generator.

Note

Rebased on main after #81 and #82. #81 moved the heaviest-term condition into heaviest_term_wanted(), which now also requires a build that is not truncated, so both heaviest-term stages (the early one after an inconclusive exact path, and the one after the exact common information stage) are skipped on a truncated build. The Windows failure of test_unconstrained_channel_survives_dit_dropping_a_light_pair before the rebase came from main, where #81 skips it.

Ryan James added 2 commits November 27, 2026 21:23
…tep is a failed snap

When the reverse epsilon-machine is infinite, the bidirectional machine
is a finite truncation, and every lower bound computed on it bounds the
truncation rather than the process, yet read "(certified)".
generative_model now skips those stages on a truncated build and reports
the larger future-window generator coverage bound at L = 2 and 3, a
lower bound on C_g that needs only the forward machine, computed first
with at most 30% of the budget. minimal_wyner_model reports lower 0
there. resolve_bidirectional classes a bidirectional machine passed in
as "truncated" when its reverse epsilon-machine is infinite (it was
always "finite").

simplex_chains._snap treats a LinAlgError from the least-squares step
as a failed snap; on a binary 3-state process it ended generative_model
after 116 s.
…'s objective

With the truncation's lower bounds skipped, later stages run on truncated
builds, whose reverse side can have ~100 states, and two of them checked
their deadlines too rarely. simplex_chain_search checked between descent
rounds, but one wall tangent is a finite-difference Jacobian over every
atom coordinate: on a 2-state ternary process with 90 reverse states
generative_model was still running at 1,020 s on a 300 s budget. Atom
steps and wall tangents now stop at the deadline. bilevel_search checked
once per Powell iteration, which line-searches every logit; on 69 reverse
states it ran 163 s past its share. Its objective now raises at the
deadline and the start keeps the best channel it scored.
@Autoplectic
Autoplectic force-pushed the truncated-window-bound branch from 7fe6643 to 1296ba7 Compare November 28, 2026 04:45
@Autoplectic
Autoplectic merged commit 836884a into main Nov 28, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant