High Performance Data Visualization for the Web [PyCon DE & PyData Berlin 2024]

Learn how Perspective library enables high-performance data visualization by combining WebAssembly, Python & TypeScript to handle large, real-time datasets on the web.

Key takeaways
  • Perspective is a high-performance data visualization library combining C++ engine (compiled to WebAssembly) with Python backend and TypeScript/Rust UI plugins

  • Supports both static and streaming data with real-time updates, originally built for finance industry use cases

  • Key features include:

    • Interactive filtering and sorting
    • Cross-filtering between multiple linked visualizations
    • Configurable views (grids, charts, maps)
    • Virtualization for handling large datasets
    • Apache Arrow for efficient data transfer
  • Architecture options:

    • Pure client-side with embedded engine
    • Client-server setup for larger datasets (4GB+)
    • Streaming support via websockets
  • Empowers end users to explore data themselves through:

    • Interactive pivoting and aggregations
    • Configurable visualizations
    • JSON-based view configurations that can be saved/loaded
    • Familiar interface for Excel users
  • Built on modern web technologies:

    • Web Components for UI
    • WebAssembly for performance
    • Apache Arrow for data transfer
    • WebSockets for streaming
  • Integrates with Python ecosystem:

    • FastAPI/Starlette for web server
    • CSP library for stream processing
    • Supports Kafka integration
    • Panel/Streamlit integration options
  • Focuses on tabular/time-series data with support for:

    • Real-time updates
    • Large datasets through virtualization
    • Complex aggregations and pivoting
    • Multiple synchronized views of same data