Skip to main content

python client for the mlsolid MLOps platform

Project description

Mlsolid-py

mlsolid-py is a python client for mlsolid MLOps platform. This python SDK allows you to track experiments and save artifacts to the mlsolid server. With Model Registries, you can easily version your machine learning models, and quickly access them in your production code.

Installation

# Install grpc client code
pip install zeddo123-mlsolid-grpc-python --extra-index-url https://buf.build/gen/python

# Install mlsolid-py module
pip install mlsolidpy

Usage

mlsolid provides an easy way to track your experiment runs:

from mlsolidpy.mlsolid import Mlsolid

client = Mlsolid('localhost:5000')

print('Experiments', client.experiments)

print('Run ', client.run("urbane-wagon"))

with client.start_run('my_experiment') as run:
    run.log({'checkpoint': "path/to/checkpoint"})
    run.log({'batch-size': 23})

    run.log({'mae': 0.2333, 'loss': 100.0})
    run.log({'mae': 0.2000, 'loss': 90})
    run.log({'mae': 0.1134, 'loss': 10})
    run.log({'metrics': [0.2000, 0.333, 0.2223]})

Model Registry example:

client = Mlsolid('localhost:5000')

created = client.create_model_registry('test_registry_1')

if not created:
    print('could not create model registry')
    exit()

run_id = None

with client.start_run('my_experiment') as run:
    run_id = run.run_id
    run.add_plaintext_artifact('./tests/data/plain_text_file.txt')
    run.add_model('./tests/data/mobile_sam.pt')

added = client.add_model('test_registry_1', run_id, 'mobile_sam.pt', ['latest'])
if not added:
    print('could not add model to registry')
    exit()

client.artifact(run_id, 'plain_text_file.txt')

client.tagged_model('test_registry_1', 'latest')

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

mlsolidpy-0.0.2.tar.gz (7.7 kB view details)

Uploaded Source

Built Distribution

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

mlsolidpy-0.0.2-py3-none-any.whl (6.2 kB view details)

Uploaded Python 3

File details

Details for the file mlsolidpy-0.0.2.tar.gz.

File metadata

  • Download URL: mlsolidpy-0.0.2.tar.gz
  • Upload date:
  • Size: 7.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.14 {"installer":{"name":"uv","version":"0.11.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"EndeavourOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for mlsolidpy-0.0.2.tar.gz
Algorithm Hash digest
SHA256 79ca945c944df7a2434ede6e5ebee64b22c62134b64863002344d4ced015f314
MD5 ec4f7e7a172c5d2077851f172f18cd61
BLAKE2b-256 841dae91a044c3b6b841ae671eecc6f6058163beb2b3561ff0ff336a74791d91

See more details on using hashes here.

File details

Details for the file mlsolidpy-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: mlsolidpy-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 6.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.14 {"installer":{"name":"uv","version":"0.11.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"EndeavourOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for mlsolidpy-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5efbea8d79a08cea9c6f356cc32f7b3a77e7f27a76676d2615654acfaeedfd50
MD5 8c15d5ff6cad96872f509e51cfcdd9af
BLAKE2b-256 36cb253e11029009361345835955fb9611d9541c4fdc67a5c3de013a10d938de

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