sclblpy
sclblpy is the core python package provided by Scailable for interacting with our API.
sclblpy is only functional in combination with a valid Scailable user account.
- Website: https://www.scailable.net
- Docs:
- On GitHub (you are here): https://github.com/scailable/sclblpy
- API docs Scailable: https://docs.sclbl.net
The scope of this package is:
Manage scailable account (auth.py)
- Create an account in the scailable plateform
- Sign in to an existing account
- Reset password or set a new password
- Get account information
Manage models (compute.py)
- Upload an
.onnxmodel to the Scailable - Update an existing model
- Delete a model
- Get model's details
- Get all the models accessible to your organisation.
- Add a catalogue (set of models) to your organisation
- Update an existing catalogue
- Delete a catalogue
- Get catalogue's details
- Get all the catalogues accessible for your organisation.
- Get the configured parameters for service
- Get statistics of all models for your organisation
Manage devices (device.py)
- Add a device to your organisation
- Update a device
- Get device's details
- Assign a model to a device
- Delete a device
- Get devices statistics
- Get all devices accessible for your organisation
- Get all groups accessible for your organisation
- Delete a group
- Add a device to a group
- Delete a device from a group
Getting started
Get a Scailable account
To create a Scailable account you can use register_() function or sign up at https://admin.sclbl.net/register
def register_(name: str, company: str, email: str, password: str, job_title: str,
phone_number: str, newsletter_optIn: bool = True, accept_eula: bool = True) -> bool:
"""Performs the sign-up of a user.
The function register performs a sign-up of a new user.
It returns a boolean value indicating whether the sign-up was successful.
Args:
name: A string (name of the user)
company: A string (name of the user's company)
email: A string (email)
password: A string (password)
job_title: A string (job of the user)
phone_number: A string (user's phone number)
newsletter_optIn: Bool (whether to add this email address to the newsletter)
accept_eula: Bool (Agreement to the EULA)
Returns:
True if sign-up is successful.
"""
You already have a Scailable account? then you can sign in to your account using log_in function.
def log_in(email: str, password: str) -> bool:
"""Performs the sign in of a user.
The function _log_in performs a log in of a user based
on the email (str) and password (str). It returns
a boolean value indicating whether the log in was successful.
Args:
email: A string (email) to log in the user
password: A string (password) for login
Returns:
True if sign in is successful.
"""
The following functionalities are likely most used:
Upload an onnx model
To upload your models to Scailable, you can use _upload_model. (only models with onnx format are accepted)
def upload_model(name: str, documentation: str, input_driver: str = "", input_driver_details: dict = {},
output_driver: str = "", output_driver_details: dict = {},
alias: str = "", path: str = "", source_name=None, source_url=None) -> bool:
"""_upload_model uploads a fitted onnx model to Scailable.
- The function first checks if the supplied path indeed references a .onnx file
- Next the onnx file and the supporting docs are uploaded.
Args:
name: Name of the model to upload
input_driver:
input_driver_details:
output_driver:
output_driver_details:
alias: Alias of the model
documentation: Documentation of the model
path: The path referencing the onnx model location (i.e., the .onnx file location).
source_name:
source_url:
Returns:
False if upload failed, True otherwise
"""
Add a device
To add a device to Scailable, you can use add_device.
def add_device(name: str, registration_token: str = "", runtime: str = "", serial: str = "", type: str = "") -> bool:
"""Add device to user's organisation.
Args:
name: Name of the model to upload
registration_token:
runtime:
serial:
type:
Returns:
True if device added, False otherwise
"""
Assign a model to a device
To assign a model to your device, you can use _assign_model_to_device.
def assign_model_to_device(uuid: str, function_uuid: str) -> bool:
"""Assign a model to a device.
Args:
uuid: UUID of the device
Returns:
True if model assigned, False otherwise
"""
Metadata
Release files for sclblpy 0.1.10
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sclblpy-0.1.10.tar.gz | 17.9 kB | Without provenance | Details for sclblpy-0.1.10.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sclblpy-0.1.10-py3-none-any.whl | Python 3 | none | any | Details for sclblpy-0.1.10-py3-none-any.whl |
Total release size: 38.3 kB
Release files / sclblpy-0.1.10.tar.gz
| Download URL | sclblpy-0.1.10.tar.gz |
|---|---|
| Size | 17.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
50697f05ac128cb142487055952418badacef7f47533b7b828ad5a8e5e9e1a16
|
|
BLAKE2b-256 checksum How to use checksums |
505cdf475025dba3d74e19e8ce23d974e286899ed1eed6e50b6f1e1b3333f70f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.16
|
Release files / sclblpy-0.1.10-py3-none-any.whl
| Download URL | sclblpy-0.1.10-py3-none-any.whl |
|---|---|
| Size | 20.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f2cc3c0769c084d538a519686f1dc21f2fbd98112e5cf2dfaf11ce199a00d1cb
|
|
BLAKE2b-256 checksum How to use checksums |
64331673d6590df9e6cbd0117848d8b9bec9b6c4acd3ea25eada10facb86407d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.16
|
Security for sclblpy 0.1.10
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.