Skip to main content

The official Python SDK to go along with Preflet.

Project description

# Preflet - Python SDK

Use this SDK to communicate with Preflet’s services to make your ML apps cloud native.

## Sample Code

from preflet import Model from preflet import generate_auth_token from preflet import list_all_models from preflet import get_model

# train_type defaults to “Classification” and can be “Multi-Class” or # “Regression” as well my_model = Model(“your_model_name”, trained_clf, train_type=”Multi-Class”)

my_model.calculate_metrics(y_test, predictions)

my_model.extract_metadata(x_train, y_train)

token = generate_auth_token(api_key=’your_api_key’)

# host can be ‘’ if you want to host it on the cloud, or # ‘localhost’ my_model.upload(token, host=’’)

# to get a list of all your models data = list_all_models(token, host=’’)

# get a specific model for normal use/batch-prediction downloaded_clf, details = get_model(“your_model_name”, token, host=’’)

# make predictions out of the box downloaded_clf.predict([…])

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

preflet-0.0.1.tar.gz (3.9 kB view hashes)

Uploaded Source

Built Distribution

preflet-0.0.1-py2-none-any.whl (4.2 kB view hashes)

Uploaded Python 2

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page