Registry / data / vispy
library0.16.2pypypi✓ verified 89d ago

VisPy is a high-performance interactive 2D/3D data visualization library in Python. It leverages the computational power of modern Graphics Processing Units (GPUs) through OpenGL to display very large datasets and facilitate real-time data visualization. Currently at version 0.16.1, the library is under active development with a roadmap towards a 1.0 release, focusing on stability, performance, and higher-level interfaces for ease of use.

pip install vispy
INSTALL
IMPORT
SIG · VISPY
V
vispy
datapythonv0.16.2
Install
4.6s avg
Import
—
Disk
107MB
Pass rate
5/ 10
Env Coverage5 / 10
glibc
3.9–3.13
musl
3.9–3.13
Install & Compatibility
Where this runs
tested against v0.16.2 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.10–3.920 runs
build_error
glibc
py 3.10–3.920 runs
installs and imports cleanly · install 4.6s · import 0.000s · 105MB
107MB installed
● package 107MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

app, scene
✓ from vispy import app, scene
Common top-level imports for creating applications and working with the scene graph.
SceneCanvas
✓ from vispy.scene import SceneCanvas
For creating an interactive 3D scene canvas.
visuals
✓ from vispy.scene import visuals
For accessing high-level visual objects like Mesh, Cube, etc.
Color
✓ from vispy.color import Color
For defining colors within VisPy.
gloo
✓ from vispy import gloo
For low-level OpenGL programming with VisPy's `gloo` interface. Note that `gloo` is slated for deprecation.

This example creates a simple interactive 3D cube using VisPy's high-level scene graph interface. It demonstrates how to initialize a canvas, set up a 3D camera, add a visual object, and run the VisPy application event loop.

import sys import numpy as np from vispy import scene, app from vispy.color import Color # Create a canvas canvas = scene.SceneCanvas(keys='interactive', size=(800, 600), show=True) canvas.title = "VisPy Cube" # Create a viewbox view = canvas.central_widget.add_view() view.camera = 'turntable' # For 3D interaction # Create a cube visual and add to the view cube_mesh = scene.visuals.Cube() view.add(cube_mesh) # Set background color view.bgcolor = Color('black') # Start the event loop if __name__ == '__main__': print("VisPy window opened. Close it to exit.") app.run()
Debug
Known issues
gotchaVisPy requires at least one GUI toolkit backend (e.g., PyQt5, PySide2, GLFW) and an up-to-date GPU driver with OpenGL 2.1+ support to function. Without these, applications may fail to run or display correctly.
fix
Ensure a compatible GUI toolkit (e.g., `pip install PyQt5`) and the latest GPU drivers are installed.
affects: All versions
gotchaPerformance can degrade significantly when creating many individual `Visual` objects. VisPy internally treats each visual as a separate OpenGL program, leading to overhead.
fix
Combine multiple graphical elements into a single `Visual` where possible (e.g., one `LineVisual` to draw multiple lines instead of many `LineVisuals`). For complex cases, consider custom visuals with optimized shader code.
affects: All versions
gotchaOpenGL operations, including calls to `self.update()` on VisPy Canvas or Visual objects, must be performed on the main/GUI thread. While data updates can occur in secondary threads, the final redraw command must originate from the main thread.
fix
Ensure all drawing and update calls that interact directly with the OpenGL context or VisPy Canvas are executed on the main GUI thread. Use thread-safe mechanisms provided by the GUI backend (e.g., signals/slots in Qt) for inter-thread communication.
affects: All versions
breakingVisPy is pre-1.0 and undergoing heavy development, meaning its internal API and behavior, especially for visuals, can change between minor versions. This has historically caused incompatibilities for applications relying on specific internal implementations.
fix
Pin `vispy` to an exact version in `requirements.txt` to prevent unexpected breaking changes. Review release notes carefully when upgrading.
affects: <1.0
deprecatedThe low-level `gloo` interface and GLIR (Graphics Library Intermediate Representation) are likely to be deprecated in future versions as development shifts focus towards higher-level interfaces.
fix
For new projects or refactoring, prioritize using the `vispy.scene` and `vispy.plot` high-level interfaces. If `gloo` is necessary, be aware of its potential deprecation and future replacement strategies.
affects: Likely >0.16.1
Upgrade
Version history
0.16.2latest on PyPI · released May 20, 2026
Audit
Dependencies
numpyrequiredMandatory requirement for array operations.
PyQt5optionalOne of several optional GUI backends required to open a window and create an OpenGL context.
PyQt6optionalOne of several optional GUI backends required to open a window and create an OpenGL context.
PySide2optionalOne of several optional GUI backends required to open a window and create an OpenGL context.
PySide6optionalOne of several optional GUI backends required to open a window and create an OpenGL context.
jupyter_rfboptionalRequired for inline visualizations in Jupyter notebooks.
PillowoptionalOptional dependency for reading image files.
Agent activity
38 hits · last 30 days
node
30
OpenAI (training)
1
Resources
vispy — pip install vispy · libregistry