Skip to main content

trame-pyvista

Trame interface for PyVista. Provides web-based 3D viewers, Jupyter backends, scene exporters, and a Sphinx directive for embedding interactive plots in docs.

This package was extracted from the pyvista.trame subpackage so the trame stack can release on its own cadence. PyVista discovers installed functionality through entry points, so existing user code keeps working once trame-pyvista is installed.

Install

pip install trame-pyvista

For Jupyter:

pip install "trame-pyvista[jupyter]"

The notebook widgets are anywidgets. When the Jupyter server runs in a separate environment from the kernel (JupyterHub, nb_conda_kernels), install anywidget in the server environment too.

For marimo:

pip install "trame-pyvista[marimo]"

What you get

  • Jupyter backends: trame, server, client, html. Registered with PyVista via the pyvista.jupyter_backends entry-point group, so pv.set_jupyter_backend('trame') works once trame-pyvista is installed.

  • marimo: with PyVista 0.50 or newer (pip install "pyvista[marimo]"), pl.show() and mesh.plot() render inline and jupyter_backend or pv.set_jupyter_backend picks the backend, as in Jupyter. With older PyVista, end a cell with pl.trame.show(mode=...) instead. html works in any marimo session, while trame, server and client need the browser on the machine running marimo. See examples/marimo/viewer.py.

  • Plotter views: PyVistaLocalView, PyVistaRemoteView, PyVistaRemoteLocalView for embedding in trame apps.

  • plotter.trame namespace: registered as a PyVista plotter component so exporters live under the trame namespace:

    import pyvista as pv
    
    pl = pv.Plotter()
    pl.add_mesh(pv.Sphere())
    pl.trame.export_vtksz('scene.vtksz')
    pl.trame.export_html('scene.html')
    
  • Sphinx directive: trame_pyvista.sphinx_ext provides the offlineviewer directive used by PyVista docs to embed exported .vtksz scenes. Add to conf.py:

    extensions = ['trame_pyvista.sphinx_ext']
    

Usage

import pyvista as pv

pv.set_jupyter_backend('trame')
pl = pv.Plotter()
pl.add_mesh(pv.Wavelet())
pl.show()

Custom UI:

from trame_pyvista import plotter_ui

ui = plotter_ui(plotter, mode='trame')

See examples/ for runnable scripts covering local/remote views, custom UIs, and toolbar customization.

Development

Uses uv and just:

just sync         # create venv and install dev deps
just test         # unit tests
just test-playwright  # Sphinx + browser integration tests
just lint         # pre-commit (ruff, etc.)
just typecheck
just build

License

MIT. See LICENSE.

Metadata

Release files for trame-pyvista 0.3.1

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

Source distribution (sdist)

Source distribution for trame-pyvista 0.3.1
File Size Uploaded Provenance Actions
trame_pyvista-0.3.1.tar.gz 128.7 kB With provenance Details for trame_pyvista-0.3.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for trame-pyvista 0.3.1
File Interpreter ABI Platform Actions
trame_pyvista-0.3.1-py3-none-any.whl Python 3 none any Details for trame_pyvista-0.3.1-py3-none-any.whl

Total release size: 172.3 kB

Release files / trame_pyvista-0.3.1.tar.gz

Download URL trame_pyvista-0.3.1.tar.gz
Size 128.7 kB
Tags Source
SHA-256 checksum
How to use checksums
962939721721b8b6b4c9f587ff3a3c4e6518854e2310617e2b7e4a5a235862b6
BLAKE2b-256 checksum
How to use checksums
d84bb9108eaa896b33c3e6a2d37dbf768333e49f16591ed5202be10602fbf561
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 1, 2026.

Transparency log

Release files / trame_pyvista-0.3.1-py3-none-any.whl

Download URL trame_pyvista-0.3.1-py3-none-any.whl
Size 43.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
eb5c24d780333504c730db8955459a78645f40d465ae6ccffdce04a647fc0bfc
BLAKE2b-256 checksum
How to use checksums
a5f75de693bf8d5c9fa0930f7f66fb02c700f5642028d3d1542da30c5a5a0274
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 1, 2026.

Transparency log

Security for trame-pyvista 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for trame_pyvista-0.3.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 1, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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