scikit-learn compatible tools to work with GBM models
Project description
scikit-gbm
scikit-learn compatible tools to work with GBM models
Installation
pip install scikit-gbm
# or
pip install git+https://github.com/krzjoa/scikit-gbm.git
Usage
For the moment, the only available class is GBMFeaturezier
. It's a wrapper around
scikit-learn GBMs, XGBoost, LightGBM and CatBoost models.
# Classification
from sklearn.datasets import make_classification
from sklearn.pipeline import Pipeline
from sklearn.linear_model import LogisticRegression
from skgbm.preprocessing import GBMFeaturizer
from xgboost import XGBClassifier
X, y = make_classification()
# train_test_split
pipeline = \
Pipeline([
('gbm_featurizer', GBMFeaturizer(XGBClassifier())),
('logistic_regression', LogisticRegression())
])
# Try also:
# ('gbm_featurizer', GBMFeaturizer(GradientBoostingClassifier())),
# ('gbm_featurizer', GBMFeaturizer(LGBMClassifier())),
# ('gbm_featurizer', GBMFeaturizer(CatBoostClassifier())),
# Regression
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
scikit-gbm-0.0.1.tar.gz
(3.9 kB
view hashes)
Built Distribution
Close
Hashes for scikit_gbm-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 847c49073ecb54f0ef1ab0a23fba75138e210d4a5df95ad4f36660bafa357173 |
|
MD5 | 83bf29106544ad2045d9e0063ee8b3fc |
|
BLAKE2b-256 | 50c3e4ae6c4235f23067a9a1b06a071a045090613a3e589063f55946177c79ea |