Technology Analysis 14 min read Prime Logic ResearchMay 26, 2026

EPANET Hydraulic Model Cloud Migration: From Desktop Simulation to Real-Time API-Driven Inference

Containerizing EPANET 2.2 as a cloud-native microservice behind a REST API enables water utilities to shift from weekly batch simulation runs to continuous 15-minute hydraulic state estimation — a transformation that unlocks pressure zone optimization, leakage localization, and demand forecasting at operational timescales.

EPANET 2.2, distributed by EPA as open-source hydraulic simulation software, remains the de facto standard for water distribution system modelling despite being architecturally designed for desktop batch execution. Its core simulation engine — a globally convergent gradient algorithm solving the nonlinear system of flow conservation and head loss equations at each network node — is computationally efficient for networks up to approximately 50,000 pipes on modern hardware, but the desktop architecture precludes the real-time integration with SCADA telemetry, demand forecasting APIs, and GIS services required for operational intelligence applications.

Containerizing the EPANET 2.2 toolkit library (libepanet) as a Python/FastAPI microservice enables cloud deployment patterns that transform the hydraulic model from a periodic planning tool into a continuous operational asset. The containerized service exposes REST endpoints for model state initialization (INP file ingestion), demand pattern updating (real-time SCADA flow and pressure injection), extended-period simulation execution, and results extraction — enabling orchestration platforms to run continuous hydraulic state estimation cycles at 15-minute intervals aligned with SCADA data acquisition frequencies.

Model calibration is the critical challenge for operational EPANET deployments. A distribution network model that accurately reflects demand patterns, pipe roughness coefficients, and valve positions during a design event can diverge significantly from observed SCADA conditions during drought periods, infrastructure rehabilitation, or demand structure changes. Online calibration approaches — parameter estimation using extended Kalman filtering, ensemble Kalman filtering, or Bayesian optimization against real-time pressure sensor observations — are required to maintain model fidelity at operational timescales. These approaches require running hundreds of parallel EPANET simulations per calibration cycle, a workload that only cloud-scale compute resources can sustain economically.

The Prime Logic Water Intelligence OS implements a production EPANET cloud deployment architecture: containerized EPANET 2.2 microservices on AWS ECS with auto-scaling groups sized for calibration workload bursts; REST API layer for SCADA system integration via OPC-UA and Modbus protocol bridges; ensemble Kalman filter calibration running against the Smart Water Platform's pressure sensor network; and continuous hydraulic state estimation results surfaced through the GIS Dashboard Suite as real-time pressure zone maps, leakage probability surfaces, and demand forecast confidence intervals — replacing static weekly simulation runs with continuously updated operational hydraulic intelligence.