Welcome to jaqpotpy documentation

About

jaqpotpy is a library that lets you deploy and share seemingless easy machine learning and statistal models over the web It is created by the Unit of Process Control and Informatics in the School of Chemical Engineering at the National Technical University of Athens.

Contact

pantelispanka@gmail.com

The application can be found at https://app.jaqpot.org

installation

Jaqpotpy can be installed as a pypi package.

Usage and initialization

Import Jaqpot

Initialize Jaqpotpy on the services that jaqpot lives.

Let jaqpot know who you are

Login and have access on the jaqpot services

In order to do so you can use the functions:

Will login and set the api key that is needed.

Same as above you request the key and set it on jaqpot

Will ask the user for the username and password by hidding the password if jaqpot is used through a jupiter notebook etc

Set Key without login

Some users may have logged in through google or github. At the account page a user can find an api key that can be used in order to have access on the services. These keys have short life and should be updated on each login.

Deploy your models!

Jaqpot and jaqpotpy are now on betta version!!!

We cannot guarantee the existence of the data

Not everything is tested thoroughly and thus things may not work as well!

Contact and let us know for any mistakes

deploy_linear_model()

Let's you deploy linear models that are created from scikit-learn

Bellow there is a list for the produced models that can be deployed with this function

deploy_linear_model() parameters are:

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

Example usage

from jaqpotpy import Jaqpot
import pandas as pd
from sklearn import linear_model



df2 = pd.read_csv('/path/train.csv')
X2 = df2[['Pclass',  'SibSp', 'Parch', 'Fare']]
y2 = df2['Survived']

clf = LogisticRegression(random_state=0, solver='lbfgs', multi_class='multinomial').fit(X2, y2)


jaqpot.deploy_linear_model(clf, X2, y2, title="Sklearn 2", description="Logistic regression model from python for the titanic dataset",
                  algorithm="logistic regression")

On the above example a linear model (in our case a logistic regression) is created and deployed on jaqpot.

The dataset is read with pandas and we created the X and y dataframes on which we trained the algorithm and created the model

For this example we used the Fame Titanic dataset. Any dataset could be used

The models should be trained with pandas dataframe!

deploy_cluster()

Let's you deploy cluster models that are created from scikit-learn

jaqpot.deploy_deploy_cluster() parameters are:

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

deploy_ensemble()

Let's you deploy cluster models that are created from scikit-learn

Algorithms:

jaqpot.deploy_ensemble() parameters are:

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

deploy_naive_bayess()

Let's you deploy naive_bayess models that are created from scikit-learn

Algorithms:

naive_bayes.BernoulliNB()
naive_bayes.GaussianNB() naive_bayes.MultinomialNB() naive_bayes.ComplementNB()

jaqpot.deploy_naive_bayess() parameters are:

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

nearest_neighbors()

Let's you deploy nearest_neighbors models that are created from scikit-learn

Algorithms:

neighbors.KNeighborsClassifier() neighbors.KNeighborsRegressor() neighbors.LocalOutlierFactor() neighbors.RadiusNeighborsClassifier() neighbors.RadiusNeighborsRegressor()
neighbors.NearestCentroid() neighbors.NearestNeighbors() neighbors.kneighbors_graph() neighbors.radius_neighbors_graph()

jaqpot.deploy_nearest_neighbors() parameters are:

if y is empty generate an empty dataframe with the title of the predicted feature

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

deploy_neural_network()

Let's you deploy neural_network models that are created from scikit-learn

Algorithms:

jaqpot.deploy_neural_network() parameters are:

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

deploy_svm()

Let's you deploy svm models that are created from scikit-learn

Algorithms:

jaqpot.deploy_svm() parameters are:

if y is empty generate an empty dataframe with the title of the predicted feature

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

deploy_tree()

Let's you deploy tree models that are created from scikit-learn

Algorithms:

jaqpot.deploy_tree() parameters are:

The id of the model is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

deploy_pipeline()

Let's you deploy pipelined models that are created from scikit-learn

jaqpot.deploy_pipeline() parameters are:

The id of the model / pipeline is returned. The model can be found on the home page of the user for editing / sharing / execution (create predictions)

Example usage

from jaqpotpy import Jaqpot
import pandas as pd
from sklearn import linear_model





df2 = pd.read_csv('/path/train.csv')
X2 = df2[['Pclass',  'SibSp', 'Parch', 'Fare']]
y2 = df2['Survived']

clf = LogisticRegression(random_state=0, solver='lbfgs', multi_class='multinomial').fit(X2, y2)


jaqpot.deploy_linear_model(clf, X2, y2, title="Sklearn 2", description="Logistic regression model from python for the titanic dataset",
                  algorithm="logistic regression")

On the above example a linear model (in our case a logistic regression) is created and deployed on jaqpot.

The dataset is read with pandas and we created the X and y dataframes on which we trained the algorithm and created the model

For this example we used the Fame Titanic dataset. Any dataset could be used

The models should be trained with pandas dataframe!