jarvis.ai.pkgs.sklearn package

Submodules

jarvis.ai.pkgs.sklearn.classification module

Simple ML models for classifcation and regression.

Designed for educational purposes only

jarvis.ai.pkgs.sklearn.classification.classification(X=[], Y=[], tol=100, plot=False, preprocess=True, models=[DecisionTreeClassifier(), MLPClassifier(), GradientBoostingClassifier(), KNeighborsClassifier(), GaussianProcessClassifier(), RandomForestClassifier(), AdaBoostClassifier(), SVC()], model_name='my_model', save_model=False)[source]

Quickly train some of the classifcation algorithms in scikit-learn.

jarvis.ai.pkgs.sklearn.classification.classify_roc_ml(X=[], y=[], classes=[0, 1, 2], names=['High val', 'Low val', ''], n_plot=1, method='', preprocess=True, plot=False, test_size=0.1)[source]

Classifcation module for ROC curve for upto three classes.

It can be expanded in more classes as well. Args:

X: input feature vectors

y: target data obtained from binary_class_dat

classes: dummy classes

names: name holders for the target data

method: ML method

preprocess: whether to apply standard preprocessing techniques

plot: whether to plot the ROC curve

jarvis.ai.pkgs.sklearn.hyper_params module

Set of ranges for hyperparameters.

# Modified from https://github.com/EpistasisLab/tpot

jarvis.ai.pkgs.sklearn.hyper_params.classification_regression_params()[source]

Set of hyperparameters.

jarvis.ai.pkgs.sklearn.regression module

Simple ML models for regression.

Designed for educational purposes only.

jarvis.ai.pkgs.sklearn.regression.regression(X=[], Y=[], plot=False, models=[GaussianProcessRegressor(), RandomForestRegressor(), GradientBoostingRegressor(), AdaBoostRegressor(), SVR(), Lasso(), LinearRegression(), KernelRidge(), MLPRegressor(), DecisionTreeRegressor()], preprocess=True, test_size=0.1)[source]

Provide model as models to get accuracy.

Args:

X: input features

Y: Target data

models : collection array of models

plot: whether to make a parity plot with ML models

preprocess: whether to apply standard preprocessing techniques

Module contents

Modules for scikit-learn appications.