Skip to content

Add KRegCCD regularisation family, UniformEscapeCCD, and PIT/held-out experiments#11

Open
alexeid wants to merge 1 commit into
CompEvol:beast3from
alexeid:add-kregccd-family
Open

Add KRegCCD regularisation family, UniformEscapeCCD, and PIT/held-out experiments#11
alexeid wants to merge 1 commit into
CompEvol:beast3from
alexeid:add-kregccd-family

Conversation

@alexeid

@alexeid alexeid commented Jun 26, 2026

Copy link
Copy Markdown
Member

Brings the full-support CCD regularisers (developed on the BEAST 2.7 line in CCD-Sophie) onto the beast3 branch. Independent beast3 port, reconciled onto this branch's scaffolding (no changes to pom.xml, module-info, or version.xml).

What's added

  • ccd.model: KRegCCD, MRegCCD, GRegCCD/GRegZApprox, NNIRegCCD; the UniformEscapeCCD trivial full-coverage baseline; the CCD0CP/CCD0SJ/CCD1CP/CCD1SJ variants with CPSupport/SJSupport; sampled-ancestor support (WrappedBeastTreeWithSampledAncestor).
  • ccd.algorithms.regularisation: KReg/MReg/NNIReg parameter optimisers and NNI clade expansion.
  • ccd.experiments.UniformEscapeComparison: held-out logP + PIT calibration across CCD1/regCCD/KRegCCD/CCD1+ε; doc/plot_pit.py renders the full-coverage PIT histograms.
  • Supporting enhancements to the shared base classes (AbstractCCD, Clade, CladePartition, RegCCD, …) that the regularisers build on.

Bug fix

CCD2(trees, burnin) reimplemented the burn-in handling instead of delegating to AbstractCCD and failed to set numBaseTrees when burnin == 0 (CCD0/CCD1 set it via super()). Surfaced by the existing CCDCoreTest.

Notes

  • The three commons-math3 optimiser users are migrated to the org.apache.commons.math4.legacy package already required by beast3 — no new dependency.
  • 45 new files, 24 updated source files; 104 tests pass, including the pre-existing CCDCoreTest.

Brings the full-support CCD regularisers from the BEAST 2.7 line
(CCD-Sophie) onto beast3:
- ccd.model: KRegCCD, MRegCCD, GRegCCD/GRegZApprox, NNIRegCCD, and the
  UniformEscapeCCD trivial full-coverage baseline; the CCD0CP/CCD0SJ/
  CCD1CP/CCD1SJ variants with CPSupport/SJSupport; sampled-ancestor
  support (WrappedBeastTreeWithSampledAncestor).
- ccd.algorithms.regularisation: KReg/MReg/NNIReg parameter optimisers
  and NNI clade expansion.
- Supporting enhancements to the shared base classes (AbstractCCD, Clade,
  CladePartition, RegCCD, ...) that the regularisers build on.

Also fixes a bug surfaced by the existing CCDCoreTest: CCD2(trees, burnin)
reimplemented the burn-in handling instead of delegating to AbstractCCD
and failed to set numBaseTrees when burnin == 0.

The three commons-math3 optimiser users are migrated to the
org.apache.commons.math4.legacy package already required by beast3.
pom.xml, module-info, and version.xml are unchanged.
@alexeid alexeid force-pushed the add-kregccd-family branch from a8008d8 to e235135 Compare June 27, 2026 01:17
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