LEAPP - Lightweight Export Annotations for Policy Pipelines: A Python package for tracing and exporting computational graphs from PyTorch code
Project description
LEAPP — Lightweight Export Annotations for Policy Pipelines
LEAPP is a Python package for tracing and exporting multi-step PyTorch computational graphs. Annotate your existing code with lightweight markers, and LEAPP captures the graph structure, exports each stage as an individual model, and generates a deployment-ready YAML specification.
LEAPP is designed for pipelines that chain multiple PyTorch models or processing stages together — where you need to export the whole pipeline, not just a single model. It traces real execution of your code, records which tensors flow between stages, exports each stage independently, and writes a YAML that describes how to wire everything back together at inference time.
Installation
pip install leapp
Quick example
import torch
import leapp
from leapp import annotate
leapp.start(name="my_pipeline")
x = annotate.input_tensors("preprocess", {"obs": torch.randn(8)})
features = (x - x.mean()) / (x.std() + 1e-6)
annotate.output_tensors("preprocess", {"features": features}, export_with="jit")
features = annotate.input_tensors("policy", {"features": features})
action = torch.tanh(features @ torch.randn(8, 4))
annotate.output_tensors("policy", {"action": action}, export_with="onnx")
leapp.stop()
leapp.compile_graph()
Running this produces a my_pipeline/ directory containing the exported models, a YAML pipeline spec, and a graph visualization.
Documentation
Full guides and API reference live at https://nvidia-isaac.github.io/leapp/:
- Getting started — install, first pipeline, generated output
- Guides — node patterns, export options, feedback graphs, semantic data, runtime validation
- API reference
License
Copyright (c) 2026, NVIDIA Corporation & affiliates. Licensed under the Apache License, Version 2.0. See LICENSE and thirdparty.txt.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
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 leapp-0.5.2-py3-none-any.whl.
File metadata
- Download URL: leapp-0.5.2-py3-none-any.whl
- Upload date:
- Size: 118.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4d041296ec49a57ecd103c8b4f280cb6f30c41dcb920eac8e4bc6e150d183ad9
|
|
| MD5 |
49c1866b07ba50c2e147ad70d0d09b0b
|
|
| BLAKE2b-256 |
d241c00072bc9648a1a728ba2174303a605a815cd3204b5bba76cff09c2efe3e
|