NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

StreamLAB: Stream-based Monitoring of Cyber-Physical Systems

Peter Faymonville, Bernd Finkbeiner, Malte Schledjewski, Maximilian Schwenger, Marvin Stenger, Leander Tentrup, Hazem Torfah

Introduction

Cyber-physical systems (CPS), such as autonomous drones and medical devices, operate in complex environments where safety is paramount. Monitoring these systems in real-time requires processing high-frequency, asynchronous sensor data while maintaining strict guarantees on memory usage and execution time. Traditional monitoring tools often assume a synchronous world where all sensors report data simultaneously. However, real-world hardware—like a drone's GPS (5Hz) and IMU (100Hz)—exhibits significant timing drift and varying frequencies. StreamLAB is a high-performance monitoring framework designed to bridge this gap using a new specification language, RTLola.

System Architecture and RTLola

The core of StreamLAB is RTLola, an extension of the stream-based language Lola. RTLola introduces two critical features for CPS: variable-rate input streams and real-time sliding windows. Unlike previous tools, RTLola accepts data as it arrives, requiring only a real-time timestamp, and allows for aggregations over time intervals (e.g., average altitude over the last 5 seconds) rather than fixed sample counts.

To maintain efficiency, StreamLAB employs a decoupled architecture that separates event-based inputs from periodic monitoring tasks.

High-level architecture of StreamLAB showing the flow from inputs through sliding windows to outputs and triggers.

As shown in the figure above, inputs are processed through sliding windows before reaching the output and trigger logic. This separation allows the system to handle fast bursts of data without blocking the evaluation of safety properties.

Implementation and Execution Model

StreamLAB is implemented in Rust to leverage its memory safety and performance. The framework's execution model is designed to handle the inherent asynchronicity of CPS data through a sophisticated scheduling mechanism.

The internal execution model of StreamLAB, featuring Event (EM) and Time (TM) Managers feeding a working queue for evaluation.

The architecture (illustrated above) utilizes an Event Manager (EM) to handle incoming sensor data and a Time Manager (TM) to manage periodic triggers. Both managers push tasks onto a central Working Queue, which is then processed by the Evaluation engine (Eval). This design ensures that the monitor remains responsive even under high load.

To guarantee predictability, StreamLAB includes a static analysis engine. This engine performs type checking and memory analysis to calculate worst-case memory consumption before execution. A key innovation is the "paning" strategy for sliding windows: time is divided into small slices, and data is pre-aggregated. This ensures that memory usage remains constant regardless of how many events occurring within a window, provided the aggregation functions are list homomorphisms (e.g., sum, count, max).

Experimental Evaluation

The authors evaluated StreamLAB using flight traces from the Ardupilot simulator. The test scenario involved a drone performing round-trips, generating data for longitude, latitude, air velocity, wind direction, and GPS satellite counts. The evaluation trace contained approximately 433,000 events.

Key results from the evaluation include:

  • Performance: On a standard i7 processor, the system processed the entire trace in 0.67 seconds, averaging 1,545 nanoseconds per event.
  • Throughput: StreamLAB achieved a maximum input frequency of 647.2 kHz, significantly higher than the requirements of typical CPS.
  • Resource Efficiency: The maximum resident set size was only 16 MB, including all bookkeeping and the C standard library, making it suitable for resource-constrained embedded platforms.
  • Reliability: The monitor successfully detected critical issues such as sensor delays, GPS failures, and unexpected hover phases.

Conclusion

StreamLAB provides a robust framework for the real-time monitoring of asynchronous cyber-physical systems. By combining the expressive power of RTLola with a predictable, high-performance execution engine, it offers a path toward safer autonomous systems. Future work includes integrating StreamLAB into physical hardware in collaboration with the German Aerospace Center (DLR) and expanding the complexity of safety specifications.

Summary updated

BibTeX
@inproceedings{faymonville2019streamlab,
  author = {Peter Faymonville and Bernd Finkbeiner and Malte Schledjewski and Maximilian Schwenger and Marvin Stenger and Leander Tentrup and Hazem Torfah},
  title = {{StreamLAB: Stream-based Monitoring of Cyber-Physical Systems}},
  booktitle = {CAV},
  year = {2019},
  doi = {10.1007/978-3-030-25540-4\_24},
}
Figure