Skip to main content

Displays the HLO representation of (un-)jitted functions as SVG

Project description

VISU-HLO

Visualizing HLO computation graphs

PyPI version Python versions Continuous integration Documentation

visu-hlo is a Python package that displays the HLO (High Level Operations) representation of JAX functions as SVG visualizations. This tool helps developers understand the computational graphs generated by JAX compilation.

Features

  • 🎯 Easy Visualization: Display HLO graphs with a single function call
  • JIT Support: Works with both regular and jitted JAX functions
  • 🖼️ SVG Output: High-quality vector graphics that scale perfectly
  • 🖥️ Cross-Platform: Supports Linux, macOS, and Windows
  • 📦 Lightweight: Minimal dependencies - just JAX and Graphviz

Quick Example

import jax.numpy as jnp
from visu_hlo import show

def func(x):
    return 3 * x * 2

# Display optimized HLO (default)
show(func, jnp.ones(10))
Optimized HLO

To display the non-optimized HLO:

show(func, jnp.ones(10), jit=False)
Non-optimized HLO

To save as an SVG file:

from visu_hlo import write_svg
write_svg('graph.svg', func, jnp.ones(10))

Installation

pip install visu-hlo

System dependency: Install Graphviz

Documentation

Full documentation: https://visu-hlo.readthedocs.io/

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

visu_hlo-1.0.0b1.tar.gz (25.5 kB view details)

Uploaded Source

Built Distribution

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

visu_hlo-1.0.0b1-py3-none-any.whl (6.4 kB view details)

Uploaded Python 3

File details

Details for the file visu_hlo-1.0.0b1.tar.gz.

File metadata

  • Download URL: visu_hlo-1.0.0b1.tar.gz
  • Upload date:
  • Size: 25.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for visu_hlo-1.0.0b1.tar.gz
Algorithm Hash digest
SHA256 2552ba38883e002ecf10ac20d0149bb830940f7d970e588dc4fc96bec1624b4d
MD5 4d05fc1bd31351e12828a8529a69f1a2
BLAKE2b-256 e36a5e5432237d6adf5947f5dfee262aaa0ec6a3a794566cc2ed80ed3cbb5cca

See more details on using hashes here.

Provenance

The following attestation bundles were made for visu_hlo-1.0.0b1.tar.gz:

Publisher: release.yml on CMBSciPol/visu-hlo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file visu_hlo-1.0.0b1-py3-none-any.whl.

File metadata

  • Download URL: visu_hlo-1.0.0b1-py3-none-any.whl
  • Upload date:
  • Size: 6.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for visu_hlo-1.0.0b1-py3-none-any.whl
Algorithm Hash digest
SHA256 21460c5a2e3efa9ddfcd51990b0b1434255b08281e6b7fd31da21df94a172277
MD5 cf18a596583869f795b52d061bcc15d2
BLAKE2b-256 7e7c657e20b6b097d3a4e219caf70864a4165761c848db9e94be0f6b115da363

See more details on using hashes here.

Provenance

The following attestation bundles were made for visu_hlo-1.0.0b1-py3-none-any.whl:

Publisher: release.yml on CMBSciPol/visu-hlo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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