Skip to main content

# 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 ‘beta.preflet.com’ if you want to host it on the cloud, or # ‘localhost’ my_model.upload(token, host=’beta.preflet.com’)

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

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

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

Metadata

Release files for preflet 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for preflet 0.0.1
File Size Uploaded
preflet-0.0.1.tar.gz 3.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for preflet 0.0.1
File Interpreter ABI Platform
preflet-0.0.1-py2-none-any.whl Python 2 none any Details

Total release size: 8.1 kB

Release files / preflet-0.0.1.tar.gz

Download URL preflet-0.0.1.tar.gz
Size 3.9 kB
Tags Source
SHA-256 checksum
How to use checksums
96dc9e4bfe02294ad48e8cbc18aa4d99dd9d66520975aee4f7445ebc6106d25d
BLAKE2b-256 checksum
How to use checksums
f1e9f2d4b3b032e8b3f22ac61d3257447a746ecf0a13cc49aa456a03f6739a3b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.34.0 CPython/3.7.3

Release files / preflet-0.0.1-py2-none-any.whl

Download URL preflet-0.0.1-py2-none-any.whl
Size 4.2 kB
Tags Python 2
SHA-256 checksum
How to use checksums
4fe581eb7d30627f0b7fb3805d903167e47bf9f32090569fc9bbecce7836ebcb
BLAKE2b-256 checksum
How to use checksums
265436a8ffd6630f191667c4818ff15207728a607d953e091f46d32116882342
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.34.0 CPython/3.7.3

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page