EQ Sight — JupyterLab

JupyterLab is an interactive Python environment for advanced analysis of power quality data. It ships only on the EQ Lab Gateway (Raspberry Pi); other EQ Gateways do not include it. On the Lab Gateway, sudo eq lab install installs JupyterLab plus equser, an open-source Python package for working with EQ Wave data. Once installed, the flask icon appears at the bottom of the EQ Sight sidebar and opens JupyterLab in a new window.

Overview

JupyterLab provides an interactive analysis environment for users who need to:

  • Perform custom calculations on waveform data
  • Create specialized visualizations
  • Develop automated analysis workflows
  • Export data in custom formats

Getting Started

When you open the JupyterLab tab:

  1. A new notebook session starts automatically
  2. The equser package is installed in the eq-lab environment and ready to use
  3. Sample notebooks in tutorials/, analysis/, and tools/ demonstrate common analysis patterns

You can also install equser on any computer with pip install equser to work with exported data or connect to a gateway remotely.

Working with CPOW Waveform Data

Load continuous point-on-wave (CPOW) parquet files directly from the gateway’s storage:

from equser.data import load_cpow_scaled

# Load a CPOW parquet file (32 ksps, 7 channels)
data = load_cpow_scaled('/var/lib/eq-coherence/data/cpow/20261001_120000.parquet')

# Scaled voltage and current arrays are ready to use
print(f"Phase A voltage range: {data['VA'].min():.1f} to {data['VA'].max():.1f} V")
print(f"Start time: {data['start_time']}")
print(f"Sample rate: {data['sample_rate']} Hz")
print(f"Samples: {len(data['VA']):,}")

The load_cpow_scaled() function automatically handles raw int32-to-float scaling using the vscale/iscale metadata embedded in each parquet file.

Querying Data via the REST API

The gateway’s REST API is available on its normal HTTP port at /api (and directly on port 8080 over the LAN). See the API Reference for endpoint details.

Metrics Data (Arrow IPC)

from equser.api import GatewayClient

# The gateway proxies /api on the normal HTTP port, so no port is needed.
client = GatewayClient('http://localhost')

# Fetch metrics records for the gateway's sensor (device id 'default'); returns a pyarrow.Table
table = client.get_pmon_data(
    'default',
    start_time='2026-10-01T12:00:00Z',
    end_time='2026-10-01T13:00:00Z',
)

df = table.to_pandas()
print(df.columns.tolist())

SQL Queries

# SELECT-only SQL against the gateway's DuckDB store; returns a pyarrow.Table.
table = client.query_sql(
    "SELECT time_us, AVRMS, BVRMS, CVRMS FROM pmon_data ORDER BY time_us DESC",
    limit=100,
)
df = table.to_pandas()

Live Streaming via WebSocket

from equser.api import connect_spectral_stream

# The spectral stream is a broadcast consumer of the live CPOW feed. Each
# binary window is a pyarrow.Table of FFT magnitudes; text messages are gap
# markers (dicts).
for item in connect_spectral_stream(channels=['VA', 'IA'], cycles=12):
    if isinstance(item, dict):
        continue  # gap marker
    print(f"Spectral window: {item.num_rows} bins, channels {item.column_names}")
    break  # Remove to stream continuously

Plotting Tools

The equser package includes plotting utilities for common visualizations:

from equser.plotting import PowerMonitorPlotter, WaveformPlotter

Waveform analysis helpers such as find_zero_crossings(), extract_complete_cycles(), and plot_extracted_cycles() are available for detailed cycle-level inspection.

Saving Work

Your notebooks are automatically saved to your user workspace. You can also:

  • Download notebooks to your local computer
  • Export results as CSV, PNG, or PDF

Resources

  • Sample Notebooks: Browse the tutorials/, analysis/, and tools/ directories in the file browser
  • API Documentation: Built-in help via help(equser)
  • equser Package: See from equser import pmon, plotting, analysis, data, api for available modules

Performance Notes

JupyterLab runs on the Lab Gateway alongside EQ Coherence and EQ Sight. For large data analyses:

  • Use time filters to limit data volume
  • Consider downsampling for trend analysis
  • Export large datasets for processing on dedicated workstations


© 2026 EQ Systems Inc. • support@eq.systems • (415) 562–5251 • Updated March 2026