Skip to main content

Nodus Python SDK

One interface for running AI workloads on GPUs.

PyPI version Python 3.10+ License: Apache 2.0

Documentation · Parameter reference · Examples · Issues

Provide a container image, a command, and a budget. Nodus finds GPU capacity and runs your workload. Use the same Python client for training, fine-tuning, or a batch of experiments.

1. Install and sign in

pip install nodus-compute
nodus login

Requires Python 3.10 or newer. Upgrading an existing installation? Use pip install --upgrade nodus-compute. Browser login without a URL requires 0.1.3 or newer.

Your browser opens Nodus sign-in. Sign in and approve the code matching your terminal. You can then close the tab. The terminal finishes automatically and saves your credentials. Python clients use that login without extra setup.

For a machine without a browser, use nodus login --no-browser. See authentication for API keys and custom deployments.

2. Run your first workload

This GPU smoke test prints the available GPU name. No local script is uploaded. It submits paid compute with a $5 workload budget. Available capacity and account limits still determine admission.

Save this as first_workload.py:

import nodus

with nodus.Client() as client:
    workload = client.run(
        image="pytorch/pytorch:2.6.0-cuda12.4-cudnn9-runtime",
        command=[
            "python", "-c",
            "import torch\n"
            "assert torch.cuda.is_available()\n"
            "print(torch.cuda.get_device_name(0))",
        ],
        compute_class="accelerator",
        model="GPU-smoke-test",
        budget=5,
    )
    print("Workload:", workload.id)
    done = workload.wait()
    print(done.status, done.cost_now_usd)
    if not done.succeeded:
        raise RuntimeError(f"Workload {done.id} ended: {done.status}")
    print(done.logs())

Run it with python first_workload.py. It prints the workload ID, waits for completion, then prints the status, current cost, and GPU name.

run() accepts the workload. wait() waits for a terminal status, so check succeeded before using results. Ctrl+C while waiting requests cancellation and remote resource cleanup.

The script prints the GPU name from the workload logs. For files produced by your own program, see logs and results.

Run your own code

Package your script and dependencies in a container image, then pass its image and command to client.run(). The SDK does not upload your local files.

For individual options, use the Python reference and parameter reference. See troubleshooting if a run fails.

Contributing

See RELEASING.md for release steps. Licensed under Apache-2.0.

Release files for nodus-compute 0.1.3

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

Source distribution (sdist)

Source distribution for nodus-compute 0.1.3
File Size Uploaded
nodus_compute-0.1.3.tar.gz 101.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for nodus-compute 0.1.3
File Interpreter ABI Platform
nodus_compute-0.1.3-py3-none-any.whl Python 3 none any Details

Total release size: 157.2 kB

Release files / nodus_compute-0.1.3.tar.gz

Download URL nodus_compute-0.1.3.tar.gz
Size 101.2 kB
Tags Source
SHA-256 checksum
How to use checksums
d521cd71db3741cd0944edf59401e9e22a6c24ed4b60c8501f4c8cfa34b1275f
BLAKE2b-256 checksum
How to use checksums
75d5813e81f4eeb3ccd2b69bff5d93889c3340367bce3c0dc8caf1827e291bea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / nodus_compute-0.1.3-py3-none-any.whl

Download URL nodus_compute-0.1.3-py3-none-any.whl
Size 56.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5519443d053788f736c2a56da0ecbc72be0bf9fe07220ad68ed929a61f0bc0fd
BLAKE2b-256 checksum
How to use checksums
125a28b2a9e925da7472f813519643a4ff4ea17bae5b9b2e42a4c5cd83b86f2a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.3.7

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

This release

0.1.3 This release

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

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