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 ‘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([…])

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 details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

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

Uploaded Python 2

File details

Details for the file preflet-0.0.1.tar.gz.

File metadata

  • Download URL: preflet-0.0.1.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using 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

File hashes

Hashes for preflet-0.0.1.tar.gz
Algorithm Hash digest
SHA256 96dc9e4bfe02294ad48e8cbc18aa4d99dd9d66520975aee4f7445ebc6106d25d
MD5 0690826ff34d4562cadedb3d6b788f22
BLAKE2b-256 f1e9f2d4b3b032e8b3f22ac61d3257447a746ecf0a13cc49aa456a03f6739a3b

See more details on using hashes here.

File details

Details for the file preflet-0.0.1-py2-none-any.whl.

File metadata

  • Download URL: preflet-0.0.1-py2-none-any.whl
  • Upload date:
  • Size: 4.2 kB
  • Tags: Python 2
  • Uploaded using 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

File hashes

Hashes for preflet-0.0.1-py2-none-any.whl
Algorithm Hash digest
SHA256 4fe581eb7d30627f0b7fb3805d903167e47bf9f32090569fc9bbecce7836ebcb
MD5 90c98271ef9601e284cb6df75fc2c3cb
BLAKE2b-256 265436a8ffd6630f191667c4818ff15207728a607d953e091f46d32116882342

See more details on using hashes here.

Supported by

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