This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import lightgbm as lgb | |
from sklearn import datasets | |
from sklearn import model_selection | |
X, y = datasets.load_boston(return_X_y=True) | |
X_fit, X_val, y_fit, y_val | |
model = lgb.LGBMRegressor() | |
model.fit(X_fit, y_fit) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> from creme import stats | |
>>> mean = stats.Mean() | |
>>> mean.update(5) | |
>>> mean.update(10) | |
>>> mean | |
7.5 | |
>>> mean.update(6) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> from creme import feature_extraction | |
>>> from creme import stats | |
>>> X = [ | |
... {'place': 'Taco Bell', 'revenue': 42}, | |
... {'place': 'Burger King', 'revenue': 16}, | |
... {'place': 'Burger King', 'revenue': 24}, | |
... {'place': 'Taco Bell', 'revenue': 58}, | |
... {'place': 'Burger King', 'revenue': 20}, | |
... {'place': 'Taco Bell', 'revenue': 50} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> from creme import compose | |
>>> from creme import datasets | |
>>> from creme import linear_model | |
>>> from creme import metrics | |
>>> from creme import preprocessing | |
>>> X_y = datasets.Phishing() | |
>>> model = compose.Pipeline( | |
... preprocessing.StandardScaler(), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Library | Method | MSE | Average fit time | Average predict time | |
---|---|---|---|---|---|
creme | LinearRegression | 23.035085 | 18μs | 4μs | |
Keras on TF (CPU) | Dense | 23.035086 | 1ms208μs | 722μs | |
PyTorch (CPU) | Linear | 23.035086 | 577μs | 187μs | |
scikit-learn | SGDRegressor | 25.295369 | 305μs | 108μs |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.