Skip to main content

scikit-gbm

Documentation Status PyPI version

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

Fo the moment, you can find the following tools in the library:

  • GBMFeaturizer
  • GBMDiscretizer
  • trees_to_dataframe
  • AXIL

Take a look at the documentation to learn more. A simple example, how to use GBMFeaturizer in a classification task.

# Classification
from sklearn.datasets import make_classification
from sklearn.model_selection import train_test_split
from sklearn.pipeline import Pipeline
from sklearn.linear_model import LogisticRegression

from skgbm.preprocessing import GBMFeaturizer
from xgboost import XGBClassifier

X, y = make_classification()
X_train, X_test, y_train, y_test = train_test_split(X, y)

pipeline = \
    Pipeline([
        ('gbm_featurizer', GBMFeaturizer(XGBClassifier())),
        ('logistic_regression', LogisticRegression())
    ])

# Try also:
# ('gbm_featurizer', GBMFeaturizer(GradientBoostingClassifier())),
# ('gbm_featurizer', GBMFeaturizer(LGBMClassifier())),
# ('gbm_featurizer', GBMFeaturizer(CatBoostClassifier())),

# Predictions for the test set
pipeline_pred = pipeline.predict(X_test)

Metadata

Release files for scikit-gbm 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for scikit-gbm 0.2.1
File Size Uploaded Provenance Actions
scikit-gbm-0.2.1.tar.gz 17.1 kB Without provenance Details for scikit-gbm-0.2.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for scikit-gbm 0.2.1
File Interpreter ABI Platform Actions
scikit_gbm-0.2.1-py3-none-any.whl Python 3 none any Details for scikit_gbm-0.2.1-py3-none-any.whl

Total release size: 39.8 kB

Release files / scikit-gbm-0.2.1.tar.gz

Download URL scikit-gbm-0.2.1.tar.gz
Size 17.1 kB
Tags Source
SHA-256 checksum
How to use checksums
c404bd890b1fc014f5d7f12e771a473dba2499e8ce578091fd98031813e79cd8
BLAKE2b-256 checksum
How to use checksums
1644d9dec201b093bee9f76c1296e374f690c047fc064374870c77dc9aae42cf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.8.10

Release files / scikit_gbm-0.2.1-py3-none-any.whl

Download URL scikit_gbm-0.2.1-py3-none-any.whl
Size 22.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ab96f12859280d7080c38b1a84dd392a7f088269f35aae6e6184ab6be568f5fe
BLAKE2b-256 checksum
How to use checksums
7ec1a876f1f200747a7df29b6483d4bc3f48d7d124ba6c1101559230ab5d5343
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.8.10

Security for scikit-gbm 0.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page