LightGBM/XGBoost interface which tunes n_estimator by splitting data, then refit with entire data
Project description
gbm_autosplit
GBM scikit-learn interfaces which performs "early stopping" with single data set during fit.
"Early stopping" is great practice to tune the number of estimators for gradient boosting models. However it is not difficult to use it in tuning module in scikit-learn such as RandomizedSearchCV / GridSearchCV because to use early stopping module requires two data sets but scikit learn does not have such interface.
To solve this situation, this interface performs following steps with in fit.
- Split original input data into two randomly
- Estimate
n_estimatorsby using split data set with early stopping - Perform
fitby using entire data set with estimatedn_estimators
Install
pip install gbm_autosplit
Usage
import gbm_autosplit
estimator = gbm_autosplit.LGBMClassifier()
estimator.fit(x, y)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gbm_autosplit-0.0.12.tar.gz.
File metadata
- Download URL: gbm_autosplit-0.0.12.tar.gz
- Upload date:
- Size: 4.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
80b5519acf20685549ad439f57cad5488c121344fb228d37e200c1f693c2b789
|
|
| MD5 |
ab01eecaaf279a2dbe8507b6147a5779
|
|
| BLAKE2b-256 |
bb0724d7a17a0ea7cecc7e966cf8b60b7c1b9a1370b30c6098ce1b6eff94ea27
|
File details
Details for the file gbm_autosplit-0.0.12-py3-none-any.whl.
File metadata
- Download URL: gbm_autosplit-0.0.12-py3-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a3ee5234a584fbc4ce2c5407269081bd0e26a80106d484e92dec4fc4eb6c755d
|
|
| MD5 |
b734a72560cf44690f80df6592ed835b
|
|
| BLAKE2b-256 |
db28dea423efe85741599f3d90c8d9247047371ce74127b5098663b1b45056a1
|