Machine Learning

Libraries for Machine Learning. Also see awesome-machine-learning.

Fit models with scikit-learn, which covers a Python machine learning library's basic tasks, boosted trees included. Deep learning takes a framework of its own.

How to choose:

  • Classification, regression, and clustering on tabular data: scikit-learn
  • Boosted trees with no extra dependency: scikit-learn
  • Causal graphs and Bayesian networks: pgmpy
  • Feature engineering that keeps your DataFrame's column names: Feature-engine
  • Boosted trees trained across a cluster: XGBoost
  • Boosted trees on large data, fast and light on memory: LightGBM
  • Tables full of category columns, with little tuning: CatBoost
  • Series with strong seasonality and holiday effects: Prophet
  • Many series on classical models like ARIMA and ETS: StatsForecast
  • Forecasting next to classification and other time-series tasks: sktime
  • Forecasts with no model to train: TimesFM

Listed in editorial order, grouped by use case. Click a column to re-sort the whole list.

Press / to search. Tap a tag to filter. Click any row for details.

Search and filter

Results

Row number Tags

General 3 projects

The most popular Python library for Machine Learning with extensive documentation and community support.
scikit-learn/github.com/scikit-learn/scikit-learn / /190,015,170 downloads/month
A Python library for causal and probabilistic reasoning with graphical models.
pgmpy/github.com/pgmpy/pgmpy / /295,914 downloads/month
sklearn compatible API with the widest toolset for feature engineering and selection.
feature-engine/github.com/feature-engine/feature_engine / /162,329 downloads/month

Gradient Boosting 3 projects

A scalable, portable, and distributed gradient boosting library.
dmlc/github.com/dmlc/xgboost / /30,481,495 downloads/month
A fast, distributed, high performance gradient boosting framework.
lightgbm-org/github.com/lightgbm-org/LightGBM / /19,243,693 downloads/month
A fast, scalable, high performance gradient boosting on decision trees library.
catboost/github.com/catboost/catboost / /5,729,178 downloads/month

Time Series Forecasting 4 projects

A tool for producing forecasts for time series with multiple seasonality and trend changes.
facebook/github.com/facebook/prophet / /4,084,637 downloads/month
Fast statistical forecasting models such as ARIMA, ETS, and Theta, compiled with numba.
Nixtla/github.com/Nixtla/statsforecast / /1,601,274 downloads/month
A unified scikit-learn-style framework for forecasting and other time-series learning tasks.
sktime/github.com/sktime/sktime / /1,142,071 downloads/month
A pretrained foundation model from Google Research for time-series forecasting, with non-commercial default weights.
google-research/github.com/google-research/timesfm / /192,850 downloads/month

Machine Learning guide

scikit-learn does supervised and unsupervised learning, plus the tools around it: preprocessing, model selection, and evaluation. Every estimator learns with fit. Put your preprocessing and model in one Pipeline, and run cross-validation and searches on that, since the pipeline keeps test data out of training. You may not need a separate boosting library: its histogram-based gradient boosting is inspired by LightGBM and supports missing values and categorical data natively. Deep learning is another matter: it doesn't fit scikit-learn's design constraints, so it's out of scope.

pgmpy does causal and probabilistic reasoning with graphical models. Its quickstart follows the tasks: learn a graph's structure from data, fit the distributions for a graph you know, then query the model for probabilities or causal effects.

Feature-engine is designed to work with dataframes: a DataFrame goes in, and the same DataFrame comes out, with no column order or name changes. Instead of wrapping transformers in a ColumnTransformer, you tell each one which variables to transform. Its transformers work just like any scikit-learn transformer, so they fit in a Pipeline.

XGBoost is an optimized distributed gradient boosting library. Its Python package has a native interface, a scikit-learn interface, and a Dask interface.

LightGBM is designed for faster training, lower memory use, and large-scale data. Pass category columns as they are: LightGBM uses them directly, with no one-hot encoding.

CatBoost aims for great results with default parameters, and it takes non-numeric features without you turning them into numbers. Name the category columns in cat_features, and don't one-hot encode them, which hurts both training speed and quality.

Prophet fits an additive model of the trend, yearly, weekly, and daily seasonality, and holiday effects. It works best with series that have strong seasonal effects and several seasons of history. It follows the scikit-learn model API: pass fit a DataFrame with ds and y columns, then call predict.

StatsForecast offers widely used univariate models, like automatic ARIMA, ETS, and Theta, optimized for speed, plus benchmark models for baselines. Data goes in as a long-format DataFrame with unique_id, ds, and y columns, and for many series the docs recommend the forecast method.

sktime gives forecasting, classification, clustering, and anomaly detection one unified interface, with interfaces to scikit-learn and Prophet. Split the series with temporal_train_test_split, set a ForecastingHorizon, then fit and predict, as in Get Started. Through reduction, a scikit-learn regressor can solve a forecasting task.

TimesFM is a pretrained foundation model from Google Research for time-series forecasting. It forecasts zero-shot, with no training on your data: load a checkpoint and call predict with a horizon. Check the license of the weights you download: some are for non-commercial, non-production use only.

To evaluate a model on time-series data, test it on observations from after its training data. scikit-learn's TimeSeriesSplit does that in cross-validation. For more, see awesome-machine-learning.

Know a project that belongs here?

Tell us what it does and why it stands out.