USGS ScienceSearch

USGS · 70032345

Automating calibration, sensitivity and uncertainty analysis of complex models using the R package Flexible Modeling Environment (FME): SWAT as an example

Abstract

Parameter optimization and uncertainty issues are a great challenge for the application of large environmental models like the Soil and Water Assessment Tool (SWAT), which is a physically-based hydrological model for simulating water and nutrient cycles at the watershed scale. In this study, we present a comprehensive modeling environment for SWAT, including automated calibration, and sensitivity and uncertainty analysis capabilities through integration with the R package Flexible Modeling Environment (FME). To address challenges (e.g., calling the model in R and transferring variables between Fortran and R) in developing such a two-language coupling framework, 1) we converted the Fortran-based SWAT model to an R function (R-SWAT) using the RFortran platform, and alternatively 2) we compiled SWAT as a Dynamic Link Library (DLL). We then wrapped SWAT (via R-SWAT) with FME to perform complex applications including parameter identifiability, inverse modeling, and sensitivity and uncertainty analysis in the R environment. The final R-SWAT-FME framework has the following key functionalities: automatic initialization of R, running Fortran-based SWAT and R commands in parallel, transferring parameters and model output between SWAT and R, and inverse modeling with visualization. To examine this framework and demonstrate how it works, a case study simulating streamflow in the Cedar River Basin in Iowa in the United Sates was used, and we compared it with the built-in auto-calibration tool of SWAT in parameter optimization. Results indicate that both methods performed well and similarly in searching a set of optimal parameters. Nonetheless, the R-SWAT-FME is more attractive due to its instant visualization, and potential to take advantage of other R packages (e.g., inverse modeling and statistical graphics). The methods presented in the paper are readily adaptable to other model applications that require capability for automated calibration, and sensitivity and uncertainty analysis.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Y. Wu, S. Liu. 2012. Automating calibration, sensitivity and uncertainty analysis of complex models using the R package Flexible Modeling Environment (FME): SWAT as an example. https://doi.org/10.1016/j.envsoft.2011.11.013

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related USGS reports

A catalogue of Do's and Don'ts in the modeling of environmental systems

Modeling plays a vital role in understanding and managing complex environmental systems, but its credibility and quality depend heavily on a comprehensive set of defensible model activities and practices, especially when the system of interest is plagued with uncertainties and conflicting stakeholder perspectives. This paper proposes a catalogue of Do's and Don'ts to guide modelers in addressing the many pertinent considerations through the whole modeling cycle. This practical tool provides advice on approaching modeling effectively through adhering to good modeling practice. It emphasizes model choices that align with the model purpose and context, and the justification and documentation of modeling decisions and assumptions. Managing uncertainty is a core consideration. The identification, assessment and reporting of these uncertainties is important across the entire modeling process, which spans problem framing, technical design, implementation and application phases. Such good practices are critical for transparency and reliability of the modeling.

Environmental Modelling and Software

Automating physics-based models to estimate thermoelectric-power water use

Thermoelectric (TE) power plants withdraw more water than any other sector of water use in the United States and consume water at rates that can be significant especially in water-stressed regions. Historical TE water-use data have been inconsistent, incomplete, or discrepant, resulting in an increased research focus on improving the accuracy and availability of TE water-use data using modeling approaches. This paper describes and benchmarks new code that was developed to automate and update a physics-based TE water use model that was previously published. Utilizing the automated physics-based model, monthly TE-power water withdrawal and consumption were calculated for a total of 1341 TE power plants for the 2008–2020 historical reanalysis. The updated and automated physics-based thermoelectric-power water-use model provides spatially and temporally relevant TE water-use estimates that are consistent, reproducible, transparent, and can be generated efficiently for water-using, utility-scale TE-power plants across conterminous United States (CONUS).

Environmental Modelling and Software

Transfer learning with convolutional neural networks for hydrological streamline delineation

Hydrological streamline delineation is critical for effective environmental management, influencing agriculture sustainability, river dynamics, watershed planning, and more. This study develops a novel approach to combining transfer learning with convolutional neural networks that capitalize on image-based pre-trained models to improve the accuracy and transferability of streamline delineation. We evaluate the performance of eleven image-based pre-trained models and a baseline model using datasets from Rowan County, North Carolina, and Covington River, Virginia in the USA. Our results demonstrate that when models are adapted to a new area, the fine-tuned ImageNet pre-trained model exhibits superior predictive accuracy, markedly higher than the models trained from scratch or those only fine-tuned on the same area. Moreover, the pre-trained model achieves better smoothness and connectivity between classified streamline channels. These findings underline the effectiveness of transfer learning in enhancing the delineation of hydrological streamlines across varied geographies, offering a scalable solution for accurate and efficient environmental modelling.

North Carolina, Virginia