Situation
Measuring how much water flows in a river has meant equipment in the water, experts on site and regular maintenance. Equipment gets damaged, and measuring during a flood is hard and dangerous, exactly when the data matters most. photrack AG in Zürich developed non-contact measurement from video, taken with a phone, a fixed camera or a drone, with its own C++ algorithm behind it. What it needed was the software around that algorithm: a cloud platform, a web application, an API, mobile apps, cloud processing, infrastructure and operations.
What we built
Since January 2016 we have built and run the Discharge platform as photrack's development partner, on a yearly roadmap, responsible for the whole platform and its infrastructure. One Django REST API of about 60 endpoints (October 2024) serves the web application, both mobile apps, the DischargeKeeper field stations and the serverless jobs. Heavy work runs in four AWS Lambda functions triggered by each upload: video processing, exports, alarms and maintenance.
The platform grew from an MVP into a multi-product system: a web platform with a REST API, cloud video processing, two generations of mobile app (Android in 2018, Flutter for iOS and Android in 2026) and the integration of autonomous DischargeKeeper stations. It widened from flow measurement to water quality and meteorology, and it now serves hydrological services, hydropower and irrigation operators, utilities, researchers and citizen-science networks in 98 countries and territories, with an interface in 8 languages. Rating curves, alarms, hardware telemetry, remote station configuration, WaterML 2.0 and ZRXP exports and a KPI dashboard complete it.
The platform was also rebuilt in place over the years. AngularJS gave way to React and TypeScript. Python was upgraded, a new CI/CD pipeline and a new export system were introduced, the plans were simplified. All of it happened while stations around the world kept sending data.

The hard part
photrack's algorithm has to give the same result wherever a measurement is processed. It runs unchanged in five places: the first Android app through JNI, the Flutter app through Dart FFI, the DischargeKeeper station, the web server and AWS Lambda, with one JSON contract between them. A measurement taken on a phone and reprocessed in the cloud is comparable with one computed at a station.
The 2026 mobile app was the latest test of that rule. We cross-compiled the engine and its dependencies for ARM on iOS and Android, wrapped 7 C functions with Dart FFI behind the same JSON contract, and retired an Android-only JNI layer. The phone processes video offline and hands the measurement to the web through a short code for precise reprocessing. Mobile results were validated against the reference desktop computation within 1 percent for scalar values. Recalculating at the real water depth takes seconds on the phone, because the computed velocity field is reused instead of recomputed.
Outcome
- More than 17 million measurements, over 6,600 users, over 1,600 organisations and over 2,200 measurement sites (October 2026).
- Measurement sites in 98 countries and territories, 47 of them with 10 or more sites and 30 with 1,000 or more measurements (29 October 2026). The largest by measurements are Germany and Switzerland, each above 4.8 million, then the Republic of Korea above 3.3 million.
- 110 fixed stations active and sending data (KPI dashboard, 2 September 2026).
- Continuous development since January 2016, several thousand commits.
- Single-station datasets of almost 500,000 measurements are handled. Large exports run asynchronously.
- A capacity analysis showed room for user growth without more expensive infrastructure.
- First iOS release of the measurement app in 2026.
What changed:
- The platform moved from AngularJS to React, through Python upgrades, a new CI/CD pipeline and a new export system, without interrupting stations reporting worldwide.
- The 2026 app brought measurement to iOS for the first time, with the same engine on five runtimes.
- Video processing runs as serverless jobs triggered by each upload rather than on a fixed server.
- API uptime of 99.9 percent over the last two years (29 October 2026).

In their words
Encode has proven to be the ideal partner to implement and evolve our ideas into a very solid and scalable system. We're building discharge.ch together.
Fact sheet
| Client | photrack AG, Zürich, Switzerland. Product: Discharge, discharge.ch. |
|---|---|
| Engagement | long-term development partner since 2016. Yearly roadmap, iterative delivery, Encode responsible for the whole platform and infrastructure. |
| In production since | January 2016. |
| How we work together | two in-person meetings a year, a roadmap in January and an alignment after summer. A weekly sync with the client's product lead, a weekly deep-dive, a Kanban board with an acceptance stage reviewed by the client. |
| Platform | Django and Django REST Framework on AWS (EC2 with Docker and NGINX, RDS PostgreSQL, S3, Lambda, CloudWatch, Secrets Manager). React 18 and TypeScript web application with 15 dynamic pages. Flutter app for iOS and Android with the C++ engine through Dart FFI. CI/CD on GitHub Actions, Sentry, Playwright. |
| Devices | DischargeKeeper autonomous field stations, with alarms, hardware telemetry, remote configuration and device registration. |
| Standards | WaterML 2.0 (OGC) and ZRXP exports. |
| Numbers, with their dates | 17,469,552 measurements and sites in 98 countries and territories (29 October 2026). 6,691 users, 1,681 organisations, 2,285 sites (public stats endpoint, 22 October 2026). 110 stations active (2 September 2026). API uptime 99.9 percent over the last two years. 8 interface languages. Refreshed on publication day. |