Python SDK for Gradlog ML experiment tracking
Project description
Gradlog Python SDK
Python SDK for Gradlog ML experiment tracking.
Installation
pip install gradlog
Quick Start
import gradlog
# Initialize the client with your API key
client = gradlog.Client(
host="https://your-gradlog-instance.com",
api_key="gl_your_api_key"
)
# Create or get a project
project = client.get_or_create_project("my-ml-project")
# Create or get an experiment
experiment = project.get_or_create_experiment("hyperparameter-search")
# Start a run
with experiment.start_run(name="run-001") as run:
# Log parameters
run.log_params({
"learning_rate": 0.001,
"batch_size": 32,
"epochs": 100
})
# Log metrics during training
for epoch in range(100):
loss = train_epoch()
run.log_metric("loss", loss, step=epoch)
run.log_metric("accuracy", evaluate(), step=epoch)
# Log artifacts
run.log_artifact("model.pt", "/path/to/model.pt")
# Run automatically completes when exiting the context
Using Raw HTTP API
You can also use the SDK to make raw API calls:
import gradlog
client = gradlog.Client(
host="https://your-gradlog-instance.com",
api_key="gl_your_api_key"
)
# Make raw API calls
response = client.get("/api/v1/projects")
projects = response.json()
Environment Variables
The SDK supports configuration via environment variables:
GRADLOG_HOST: The Gradlog server URLGRADLOG_API_KEY: Your API key
import gradlog
# Will use environment variables
client = gradlog.Client()
License
MIT
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gradlog-0.1.1.tar.gz.
File metadata
- Download URL: gradlog-0.1.1.tar.gz
- Upload date:
- Size: 9.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dce0d06525f4914207e0652df7fb1510523d31024c4b59942bf2265026dc8065
|
|
| MD5 |
b4a1cd1e20d78d58720227bf46f46ee4
|
|
| BLAKE2b-256 |
a347039d246b87728230b0508435d33d962485852d6dde01dadeb7832f7813ff
|
Provenance
The following attestation bundles were made for gradlog-0.1.1.tar.gz:
Publisher:
publish-sdk.yml on verynewusername/gradlog
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gradlog-0.1.1.tar.gz -
Subject digest:
dce0d06525f4914207e0652df7fb1510523d31024c4b59942bf2265026dc8065 - Sigstore transparency entry: 1092853544
- Sigstore integration time:
-
Permalink:
verynewusername/gradlog@645f7c81ad5fe8b559cb46f9bc9b7528827ad532 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/verynewusername
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-sdk.yml@645f7c81ad5fe8b559cb46f9bc9b7528827ad532 -
Trigger Event:
push
-
Statement type:
File details
Details for the file gradlog-0.1.1-py3-none-any.whl.
File metadata
- Download URL: gradlog-0.1.1-py3-none-any.whl
- Upload date:
- Size: 10.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
73b30f26f620cdb87e3eaa45232b4fadbd736e2835c24dd358eafe88315cb9bd
|
|
| MD5 |
6fce0b626e1dd4fb3c422c35c7345c35
|
|
| BLAKE2b-256 |
ca05d88c56e5d6cd7ee5dd632760f3673ad0dba891540ccd585e4348a030da22
|
Provenance
The following attestation bundles were made for gradlog-0.1.1-py3-none-any.whl:
Publisher:
publish-sdk.yml on verynewusername/gradlog
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gradlog-0.1.1-py3-none-any.whl -
Subject digest:
73b30f26f620cdb87e3eaa45232b4fadbd736e2835c24dd358eafe88315cb9bd - Sigstore transparency entry: 1092853547
- Sigstore integration time:
-
Permalink:
verynewusername/gradlog@645f7c81ad5fe8b559cb46f9bc9b7528827ad532 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/verynewusername
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-sdk.yml@645f7c81ad5fe8b559cb46f9bc9b7528827ad532 -
Trigger Event:
push
-
Statement type: