Skip to main content

srbf: Symbolic Regression Benchmark Framework

srbf evaluates symbolic-regression models on shared benchmarks with shared metrics. It is the evaluation framework carved out of flash-ansr: the evaluation engine, model adapters, benchmarks, and metrics. It depends one-way on flash-ansr (srbf imports flash-ansr; flash-ansr never imports srbf).

Built for contributions. Developers of SR methods add their model by opening a PR with an adapter (two methods) plus install instructions. The built-in adapters (flash_ansr, pysr, nesymres, e2e, skeleton_pool, brute_force) are reference examples, not a closed set. See the adapter contribution guide.

Status: 0.1, cleanly-carved eval. The engine seam (srbf.eval.core Protocols + srbf.eval.engine) is model-agnostic, but every built-in adapter imports flash-ansr and the adapter set is a registry edited by PR. A plugin register_adapter() entry-point and raw-dataset ((X, y) CSV/parquet) ingestion are planned follow-ons.

Install

pip install srbf                 # engine + metrics + the pip-installable adapters (flash-ansr, PySR)
pip install "srbf[baselines]"    # + pip baseline deps (sympy, pysr, omegaconf)

srbf pulls in flash-ansr and simplipy automatically. The unpackaged research baselines (NeSymReS, E2E) are provisioned out-of-band; see docs/models.md.

Quickstart

# 1. point srbf at a tree holding configs/, data/, and models/ (your srbf checkout works)
export FLASH_ANSR_ROOT=$(pwd)

# 2. get a model to evaluate (flash-ansr's CLI ships with srbf)
flash_ansr install psaegert/flash-ansr-v23.0-3M

# 3. fetch a benchmark + build its skeleton pool   (see docs/benchmarks.md)
#    ...then run an evaluation:
srbf run -c configs/evaluation/scaling/v23.0-3M_val.yaml --limit 50 -v

Outputs land under results/evaluation/.../*.pkl, one row per evaluated dataset with flat metric columns. Run programmatically instead:

from srbf import build_evaluation_run

plan = build_evaluation_run(config="configs/evaluation/scaling/v23.0-3M_val.yaml")
plan.engine.run(limit=plan.remaining, output_path=plan.output_path)

Documentation

Guide What it covers
Running evaluations the srbf run CLI, config anatomy (data_source / model_adapter / runner / experiments), outputs, resume
Benchmarks & datasets fetching FastSRB, building skeleton pools with flash_ansr import-data, custom sets
Models & provisioning installing/patching the built-in models; the model_adapter block per type
Adding your model the adapter protocol + registry, and the PR flow to contribute a new SR method

Development

pip install -e ".[dev]"
pre-commit run --all-files
pytest tests

License

MIT (see LICENSE). Third-party attributions in THIRD_PARTY_LICENSES.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

srbf-0.3.0.tar.gz (76.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

srbf-0.3.0-py3-none-any.whl (82.2 kB view details)

Uploaded Python 3

File details

Details for the file srbf-0.3.0.tar.gz.

File metadata

  • Download URL: srbf-0.3.0.tar.gz
  • Upload date:
  • Size: 76.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for srbf-0.3.0.tar.gz
Algorithm Hash digest
SHA256 6a0a234ab1f6853257d5a3d76b49ec42e9defc41a3c0d96efb95dc809c00b405
MD5 5241dfc96763b9245e38af190178004a
BLAKE2b-256 cbc2dda57823a9fc79f1b51c5f73e26b132e1e6794dca9327e6cc38ba5c9c150

See more details on using hashes here.

Provenance

The following attestation bundles were made for srbf-0.3.0.tar.gz:

Publisher: publish.yaml on psaegert/srbf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file srbf-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: srbf-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 82.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for srbf-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 aceb37dd7616894843cdb0e4c14ff9edb346b3e041aad3937975e625f80d0826
MD5 b933a7032bb192b93503ef2cad100e3f
BLAKE2b-256 5ad7fad95f4d7d5bd3e276c4859ef29bdf63e049037f906a5b78b98c2922ba47

See more details on using hashes here.

Provenance

The following attestation bundles were made for srbf-0.3.0-py3-none-any.whl:

Publisher: publish.yaml on psaegert/srbf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page