Automate machine learning classification task report for Pak Zuherman
Project description
Classification Reportzr
Automate machine learning classification task report for Pak Zuherman
Install
pip install -U classification-reportzr
Test
pytest -v
Usage
Setting-up the experiment
from sklearn import datasets
from sklearn.svm import SVC
from reporterzr import Reporterzr
iris = datasets.load_iris()
samples, labels = iris.data[:-1], iris.target[:-1]
param_grid = {
'C': [10,50,100],
'gamma': [0.005,0.05,0.5],
'kernel': ['poly', 'rbf', 'linear']
}
svc_reporter = Reporterzr(SVC, param_grid)
Run The Experiment
# `test_sizes` defaults to [0.1, ..., 0.9]
# `repetition` defaults to 10
report = svc_reporter.run_experiment(samples, labels, test_sizes=[0.1, 0.2], repetition=5)
print(report)
prints
Test Size C gamma kernel Train Accuracies \
0 0.1 10 0.005 poly [0.881, 0.896, 0.888, 0.881, 0.873]
1 0.1 10 0.005 rbf [0.978, 0.978, 0.97, 0.97, 0.97]
2 0.1 10 0.005 linear [0.978, 0.978, 0.978, 0.978, 0.978]
3 0.1 10 0.050 poly [0.978, 0.978, 0.978, 0.978, 0.978]
4 0.1 10 0.050 rbf [0.993, 0.985, 0.993, 0.985, 0.985]
Max Train Mean Train Stdev Train Test Accuracies \
0 0.896 0.884 0.008 [0.933, 0.8, 0.8, 1.0, 1.0]
1 0.978 0.973 0.004 [0.933, 0.867, 0.933, 0.8, 0.933]
2 0.978 0.978 0.000 [0.933, 1.0, 1.0, 0.933, 1.0]
3 0.978 0.978 0.000 [1.0, 1.0, 1.0, 1.0, 1.0]
4 0.993 0.988 0.004 [0.933, 1.0, 0.933, 1.0, 1.0]
Max Test Mean Test Stdev Test \
0 1.000 0.907 0.090
1 0.933 0.893 0.053
2 1.000 0.973 0.033
3 1.000 1.000 0.000
4 1.000 0.973 0.033
Experiment Times
0 [0.00086, 0.00076, 0.0007, 0.00071, 0.00069]
1 [0.00075, 0.00075, 0.00073, 0.00074, 0.00074]
2 [0.00048, 0.00046, 0.00046, 0.00045, 0.00046]
3 [0.00046, 0.00049, 0.00048, 0.00048, 0.00047]
4 [0.00061, 0.00058, 0.00057, 0.00059, 0.00059]
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
Close
Hashes for classification-reportzr-0.0.1b8.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1d14829eac3bc2de4a426067adb04918e533b63466ec3e6def04d6c8e584092c |
|
MD5 | d2150d96e68c19c39ee17d5934fbb5a8 |
|
BLAKE2b-256 | befa1c7d2f9adf997298cf1e4d23b33ea9b5f412cfa5fe6848d6047893dd68a0 |
Close
Hashes for classification_reportzr-0.0.1b8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c05b1dfa1360301ed3a61f2ec3e858aaa8623ee70233c3312cb033ecd7608bfd |
|
MD5 | 437985ce1b53ba42859183644b518006 |
|
BLAKE2b-256 | abe6814b75158d60e00bdab4a93dcc806036840ebfe61b8034442fa4d48b6cf2 |