Skip to content

Add GP_ELITE (pure-Python GP, LM constants, optional dimensional constraints) - #212

Open
ariel95500-create wants to merge 6 commits into
cavalab:masterfrom
ariel95500-create:master
Open

Add GP_ELITE (pure-Python GP, LM constants, optional dimensional constraints)#212
ariel95500-create wants to merge 6 commits into
cavalab:masterfrom
ariel95500-create:master

Conversation

@ariel95500-create

Copy link
Copy Markdown

This PR adds GP_ELITE, a pure-Python symbolic regression library
(pip install gp-elite, MIT).

Method: genetic programming with island parallelism, Levenberg-Marquardt
constant optimization, native multi-restart with merged archives, and a
complexity/accuracy Pareto front. The regressor passes scikit-learn's
check_estimator, implements max_time via time-boxed sequential restarts,
and model() returns a sympy-compatible string using the dataset column
names, with input normalization folded in (the string reproduces
est.predict on raw features to ~1e-12).

Internal run of the SRBench ground-truth protocol on the 119 Feynman
datasets (10k rows, 75/25 split, 3 seeds, R2_test>0.999): 60.2% of runs
solved, 69% of datasets solved by at least one seed, median R2 0.99973.
Raw jsonl logs and the runner are available in the project repo.

Repo: https://github.com/ariel95500-create/gp-elite
Happy to adjust anything to fit the harness.

@ariel95500-create ariel95500-create changed the title Add GP_ELITE (pure-Python GP with Levenberg-Marquardt constants) Add GP_ELITE (pure-Python GP, LM constants, optional dimensional constraints) Jul 27, 2026
@ariel95500-create

Copy link
Copy Markdown
Author

Bumped to gp-elite 0.4.1 (now on PyPI) and updated metadata.yml.

0.4.1 fixes a silent float64 overflow in the Levenberg-Marquardt constant
optimizer: unbounded sq/cube/* chains could reach ~1e198 and overflow during
the Jacobian products, degrading fits without raising. It also fixes two bugs
in the optional dimensionally-constrained search mode, which is not exercised
here since the harness does not pass units.

For reference, build-and-test (gp-elite) is green on this run (7m). The 10
failing checks are other algorithms (brush, bsr, e2et, eql, feat, nesymres,
operon, pysr, sklearn, tpsr); operon passed on the previous run and failed on
this one without any change to it, so these look unrelated to this submission.

Happy to adjust anything to fit the harness.

Add metadata for GP_ELITE symbolic regression package
Implement GPEliteSRBench class for symbolic regression with time constraints.
@ariel95500-create

Copy link
Copy Markdown
Author

Reopening — the branch was accidentally reset while syncing the fork,
which emptied this PR. Files restored, now targeting gp-elite 0.5.0.

Implemented GPEliteSRBench class for symbolic regression with time constraints and multiple restarts. Added methods for fitting the model, generating sympy expressions, and calculating model complexity.
@ariel95500-create

Copy link
Copy Markdown
Author

Restored after an accidental fork sync emptied this PR — the branch was
reset and the files were lost. Everything is back, now targeting gp-elite
0.5.0, which adds an optional mode that deduces the units and value of a
law's missing physical constant (not exercised here, as the harness does
not pass units).

build-and-test (gp-elite) is green on this run (8m). The remaining
failures are other algorithms and predate this PR.

Apologies for the churn.

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.

2 participants