April to August 2023 Edition

Automated Testing for Water Resources Models

By Dr. Anurag Mishra - Geosyntec Consultants

Numerical modeling is an essential aspect of water resources engineering. These models are used for predicting flow and water quality to support planning projects varying in size from a block to millions of square miles. 

These numerical models go through continuous development by different practitioners, and the development process is not always linear and does not follow the same standard practices. The versions of these models may not always go through a standardized testing process. However, the practitioners who are applying these models for their project trust that the model code has been reviewed and tested by multiple experts. 

DSI focusses on the development of Environmental Fluid Dynamics Code Plus (EFDC+), which is an enhanced version of EFDC, developed initially by USEPA support. EFDC and EFDC+ has been applied to thousands of water bodies around the world to model hydrodynamics, sediment transport, chemical fate and transport, and water quality. In Washington, it is being applied to develop a hydro-thermal model of the Lake Washington and a water quality model for the Lower Duwamish Waterway. 

Until recently, even the source code of EFDC was not available to most of the modeling community. As EFDC+ developers, DSI has focused on intensive testing of the code, before releasing it to the modeling community. However, as experience would suggest, even if we test our new code for a specific application, it may cause unintended changes in different applications. It is resource intensive to test a code change for every possible model application. 

To improve model testing efficiency and increase the trust in new model versions and their outputs, DSI developed a model testing tool. The process flow of this tool is very simple. With every change in the EFDC+ code, the testing tool compiles the software and runs a batch of sixty models that are categorized based on their levels of complexity. The testing tool then compares the outputs from all models based on previous successful model runs and reports all significant differences (e.g., Figure 1). The model developer can review the differences in results and accept or reject the new code change.

Figure 1: An Example of Automated Testing Tool Output: Time series plots of maximum absolute error for COD, DOC, DON, and DOP in different model versions.

A graph of different types of graphs Description automatically generated with medium confidence

Although DSI has applied this tool for developing EFDC+, we believe similar testing tools could be developed for other water resources modeling software.

                               

Questions about the website? Please contact the Webmaster: waawra.webmaster@gmail.com.
Powered by Wild Apricot Membership Software