Skip to main content

SmallGBM

Gradient boosting that actually works on small data.

version python license pip


Why SmallGBM?

XGBoost and LightGBM are built for scale. They shine on thousands of rows. But when you only have 50, 100, or 500 samples, their default hyperparameters fail — overfitting, instability, unpredictable results.

SmallGBM is designed from the ground up for datasets with fewer than 1000 samples.

Feature SmallGBM XGBoost LightGBM
Bayesian leaf weights
Adaptive regularization
No bootstrap (uses all data)
Stable under label noise
scikit-learn compatible

Noise Stability

SmallGBM degrades gracefully when labels are noisy — unlike XGBoost and LightGBM which drop sharply.

Noise stability comparison

At 20% label noise, SmallGBM is the best performer. Bayesian regularization keeps it stable when others collapse.


Learning Curve

Clear, predictable improvement as data grows. Reliable performance starts at n ≈ 40.

Learning curve

No sudden jumps, no catastrophic failures. A safe choice when data is limited.


Installation

pip install smallgbm

Quickstart

from smallgbm import SmallGBMClassifier

model = SmallGBMClassifier()
model.fit(X_train, y_train)
proba = model.predict_proba(X_test)

API

SmallGBMClassifier

Parameter Default Description
n_estimators 50 Number of boosting rounds
max_depth 3 Maximum tree depth
min_samples_leaf 3 Minimum samples per leaf
learning_rate 0.1 Shrinkage factor
sigma_prior 0.5 Bayesian prior strength

SmallGBMRegressor

Same parameters, for regression tasks.

from smallgbm import SmallGBMRegressor

model = SmallGBMRegressor()
model.fit(X_train, y_train)
preds = model.predict(X_test)

Research

Full characterisation notebook with 5 experiments: benchmark_final.ipynb

  • Noise stability analysis
  • Prior sensitivity
  • Sample size curve
  • Regression performance
  • Class imbalance tolerance

License

MIT © Emelyanov Ilya 2026


Built with ❤️ for the small data community

Download files

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

Source Distribution

smallgbm-1.0.1.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

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

smallgbm-1.0.1-py3-none-any.whl (6.4 kB view details)

Uploaded Python 3

File details

Details for the file smallgbm-1.0.1.tar.gz.

File metadata

  • Download URL: smallgbm-1.0.1.tar.gz
  • Upload date:
  • Size: 6.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.15.0a5

File hashes

Hashes for smallgbm-1.0.1.tar.gz
Algorithm Hash digest
SHA256 3408e61abdeecf8ac19e4eb3f7df8f098e1cfbe5176b02d85ba6a440dd764051
MD5 18c0b2df7f90bb8312565b3e325fe952
BLAKE2b-256 4cb3440972014e965450d9a84cda7c850f87b8476e8d5cf0d5ca7b493689955c

See more details on using hashes here.

File details

Details for the file smallgbm-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: smallgbm-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 6.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.15.0a5

File hashes

Hashes for smallgbm-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5ad2366c9004f0b322016424d5c2e1c421ffaa1c988ad99684e942629686ef3f
MD5 167a683c3e5c4e007769261733141907
BLAKE2b-256 6072e2ff5d19498ca5ec853526ee958ae4765096a9405919e28256e8d3d05bfc

See more details on using hashes here.

Release history Release notifications | RSS feed

1.4.1

2 files

1.4.0

2 files

1.3.0

2 files

1.2.0

2 files

1.1.0

2 files

This release

1.0.1 This release

2 files

1.0.0

2 files

Supported by

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