Repository navigation
Speed up bar's base aligners: pecan, minipoa and abPOA - #2026
Merged
Merged
Conversation
Bumps cPecan to faster-pecan (12ce978): an exact, probability-space forward-backward 5-11x faster per pairwise alignment that recomputes large unanchored chunks in blocks instead of holding them (3.9GB -> 116MB for a 10kb pair), an array-based progressive MSA (same output, 2x faster, half the memory), and in-process seed anchoring. The anchoring is what decides pecan's accuracy on deep branches. The MUM anchors bar used accept "unique" matches of a dozen bases, and at 0.3 substitutions per site per branch half of them are off the true alignment and drag the banded dp with them. <pecan anchorMethod="seed"> is now shipped: lastz's recipe (spaced seeds, ungapped extension, chaining) without a lastz process per alignment. anchorMethod="mum" or "lastz" select the old ones; without the attribute useMumAnchors decides as before. Evolver mammals, mafComparator: abpoa 0.853/0.652, pecan before 0.859/0.654, pecan now 0.869/0.666, with bar taking 1-3s per ancestor against abpoa's 0-3s (stock pecan 1-10s). Evolver primates: abpoa 0.9973/0.9844, pecan 0.9977/0.9846. 8Mb of human/mouse: bar 26s/0.5GB against abpoa's 59s/6.7GB, aligning slightly more of human to mouse. On evolver-like inputs pecan still spends about twice abpoa's CPU in bar, so baseAligner stays abpoa. <bar deepAligner deepAlignerDivergence> use deepAligner for ancestors whose two farthest children are at least that far apart in the scaled tree the workflow already uses for its divergence settings. Off by default (0); with branchScale 2, 0.5 picks the deepest 15% of the VGP 577-way's ancestors. Fixes in bar: aligning only the dominant end is now taken only when no adjacency is longer than bandingLimit -- it allowed twice that, leaving the far part of such adjacencies unaligned; flowerAligner.c includes its own header, which shows makeFlowerAlignment's definition had a parameter its declaration lacks. The bar log line names the anchor method. New evolver tests run pecan on primates and mammals. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Bumps minipoa to 0416daa (ai-optimization), which vectorises and streams its DP, keeps its scratch between windows, centres its band better, adds an optional convex gap, and fixes its guide tree below 8 sequences. <minipoa> now ships the convex gap abpoa uses (400/30 and 1200/1, via the new minipoaGapOpenPenalty2/minipoaGapExtensionPenalty2) and progressive mode on. Evolver mammals: 0.846/0.646 -> 0.854/0.652, against abpoa's 0.853/0.652; primates unchanged. On 8Mb of human/mouse at 8 threads, bar takes 14s and 5.6GB against abpoa's 59s and 6.7GB (10s and 3.5GB with the second gap piece off, where the old minipoa took 29s and 3.1GB for identical output). last-train now turns the second piece off, so minipoa runs the trained single affine model as trained. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
minipoa's DP now keeps two bits a cell for each horizontal gap state instead of a 16-bit value, with alignments unchanged. On 8Mb of human/mouse at 8 threads, bar with the shipped <minipoa> settings goes from 14s and 5.6GB to 12s and 4GB (abpoa: 59s and 6.7GB), and with a single affine gap from 10s and 3.5GB to 9s and 2.8GB. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Points submodules/abPOA at ComparativeGenomicsToolkit/abPOA instead of upstream yangao07/abPOA, at 6e02e17 (branch ai-optimization): upstream's current main, which aligns exactly as the v1.5.6 we had, plus one change -- each DP row keeps only its band, packed next to the others, where every row used to be stored at full query width. Alignments are unchanged: bar's output on 8Mb of human/mouse is identical, as is evolver mammals (0.8526/0.6521). There, bar went from 59s and 6.9GB to 51s and 5.5GB at 8 threads. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 2, 2026
The three aligner PRs are merged, so the submodules move from their feature branches to the merge commits: cPecan master (55920ef, cPecan#9), abPOA main (36110ac, abPOA#12) and minipoa cactus-integration (d8050a1, minipoa#2). cPecan's and minipoa's trees are the ones already tested. minipoa now also has ofirr's fix for "backtrack found no predecessor" (minipoa#1), ported to the convex traceback; the commit pinned before got through those windows only by retrying them unbanded. abPOA's main adds upstream's v1.5.7 release metadata, none of it in the library. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
So CI runs on the combined code. master's 23 commits (last-train on by default in the pangenome pipeline, minigraph penalties from its model, the hal2vg build, guards against giant snarls) merge without conflicts. Four files changed on both sides, in different places: the config (the bar sections here; <poa>'s trained long-gap factor and <graphmap> on master), last_scoring.py, evolverTest.py and the Makefile. In last_scoring.py master now scales the trained matrix and gaps together, and that scaled model is what this branch hands minipoa, so minipoa's trained scores stay consistent too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Speeds up all three of bar's base aligners, makes minipoa as accurate as abPOA, and makes pecan practical again for progressive alignment. The default aligner does not change (
<bar baseAligner="abpoa">), and abPOA's output is identical to before.pecan: cPecan
master(55920ef, ComparativeGenomicsToolkit/cPecan#9)<pecan anchorMethod="seed">. The old MUM anchors accept "unique" matches of about a dozen bases; at 0.3 substitutions per site per branch, half of them are off the true alignment. That, not the HMM, is why pecan degraded on deep branches.<bar deepAligner deepAlignerDivergence>can switch the deepest ancestors to pecan. It is off by default.minipoa:
cactus-integration(d8050a1, ComparativeGenomicsToolkit/minipoa#2)minipoaGapOpenPenalty2/minipoaGapExtensionPenalty2), and the guide tree fixed (below 8 sequences it kept the input order).<minipoa>now ships abPOA's convex gaps (400/30 + 1200/1) with the guide tree on.abPOA: ComparativeGenomicsToolkit fork,
main(36110ac, ComparativeGenomicsToolkit/abPOA#12)yangao07/abPOAtoComparativeGenomicsToolkit/abPOA. The pinned commit is upstream's currentmain, which aligns identically to the v1.5.6 we had, plus one change: each DP row stores only its band, packed together, instead of the full query width.bar
bandingLimit; it allowed twice that, leaving the far part of such adjacencies unaligned.Updating an existing clone
The abPOA URL changed, so after pulling run
git submodule sync && git submodule update --init --recursive, or the update will look for the new commit upstream and fail.Testing
tests/run_all.sh.Before merging
masterin (d429818), so CI runs on the combined code. Its 23 commits merged without conflicts.🤖 Generated with Claude Code