trevorstephens/gplearn
Genetic Programming in Python, with a scikit-learn inspired API
What it solves
It provides a way to find mathematical expressions that describe the relationship between variables. Instead of traditional machine learning models that are "black boxes," this tool uses symbolic regression to discover a readable formula that best fits the data.
How it works
The library implements Genetic Programming (GP). It starts with a population of random mathematical formulas. It then evolves these formulas over multiple generations, selecting the fittest individuals based on their performance and applying genetic operations to create new, improved versions until an optimal expression is found.
Who it’s for
Data scientists and machine learning practitioners who use the scikit-learn ecosystem and want to perform symbolic regression, binary classification, or automated feature engineering.
Highlights
- Scikit-learn compatible API using the familiar
fit/predict pattern.
- Supports symbolic regression via the
SymbolicRegressor.
- Supports binary classification via the
SymbolicClassifier.
- Enables automated feature engineering through the
SymbolicTransformer.
- Integrates with scikit-learn pipelines and grid search modules.
Related
- Project
feature-engine/feature_engineA Python library providing Scikit-learn compatible transformers for comprehensive feature engineering and selection to improve machine learning model performance.
- Project
rodrigo-arenas/Sklearn-genetic-optA scikit-learn compatible optimization toolkit that uses genetic algorithms for hyperparameter tuning and feature selection in mixed search spaces.
- Project
astroautomata/SymbolicRegression.jlSymbolicRegression.jl is a Julia library that automatically discovers interpretable mathematical formulas fitting a dataset, using evolutionary symbolic search. It offers a high‑level MLJ‑style API (`SRRegressor`, `machine`, `fit!`, `predict`) and a low‑level `equation_search` function for custom control. Results are returned as callable expression trees, which can be inspected, evaluated, or converted to SymbolicUtils for further manipulation. The package integrates with MLJ pipelines, includes CI/testing, and is backed by an arXiv paper and a Python front‑end (PySR).
- Project
google/pygloveA symbolic programming library for Python that enables the manipulation and automatic search of Python programs, commonly used for AutoML and evolutionary computing.
- Project
skforecast/skforecastA Python library for time series forecasting that provides a unified API for scikit-learn compatible ML models, statistical methods, and zero-shot foundation models.