EMP metrics and models for scikit-learn
Project description
empulse
Empulse is a package aimed to enable value-driven analysis in Python. The package implements popular value-driven metrics and algorithms in accordance to sci-kit learn conventions. This allows the measures to seamlessly integrate into existing ML workflows..
Installation
Install empulse
via pip with
pip install empulse
Documentation
TODO: add documentation
Usage
We offer custom metrics and models. You can use them within the scikit-learn ecosystem.
# the scikit learn stuff we love
from sklearn.preprocessing import StandardScaler
from sklearn.pipeline import Pipeline
from sklearn.datasets import make_classification
from sklearn.model_selection import cross_val_score
from sklearn.metrics import make_scorer
from sklearn.linear_model import LogisticRegression
# the stuff we add
from empulse.metrics import empc_score
X, y = make_classification()
pipeline = Pipeline([
("scale", StandardScaler()),
("model", LogisticRegression())
])
cross_val_score(pipeline, X, y, scoring=make_scorer(empc_score, needs_proba=True))
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
empulse-0.0.14.tar.gz
(39.7 kB
view hashes)
Built Distribution
empulse-0.0.14-py3-none-any.whl
(54.5 kB
view hashes)