Skip to yearly menu bar Skip to main content

Workshop: Computational Sustainability: Promises and Pitfalls from Theory to Deployment

Segment Any Stream: Scalable Water Extent Detection with the Segment Anything Model

Haozhen Zheng · Chenhui Zhang · Kaiyu Guan · Yawen Deng · Sherrie Wang · Bruce Rhoads · Andrew J Margenot · Shengnan Zhou · Sheng Wang

Abstract: The accurate detection of water extent in streams and rivers is pivotal to understanding inland water hydrodynamics and terrestrial-aquatic interactions of biogeochemical cycles, in particular bank erosion and the resulting transfer of nutrient elements such as phosphorus (P). This is highly relevant to the United Nations Sustainable Development Goals (SDGs), notably sustainable land use (Goal 15) and climate change mitigation (Goal 13), as well as national to regional water quality efforts, notably the Mississippi River Basin nutrient reduction targets set by U.S. Environmental Protection Agency (EPA). Prior studies have employed a variety of computational methods, ranging from hand-crafted decision rules based on spectral indices to advanced image segmentation techniques. However, these methods are limited in their generalizability when implemented in new regions. Furthermore, the recent development of vision foundation models such as the Segment Anything Model (***SAM***) has brought about opportunities for water extent detection due to their exceptional generalization capabilities. ***SAM*** has few-shot or even zero-shot generalization, which emerged from pretraining a large model with an enormous amount of data. Nevertheless, the adaptation of these models remains challenging due to the computational overhead of fully fine-tuning the entire model and the potential degradation in their emergent capabilities when the data is out-of-distribution. Taking these desiderata into account, this work proposes $\underline{\textbf{S}}$egment $\underline{\textbf{A}}$ny $\underline{\textbf{S}}$tream ***SAS***, which employs the Low-Rank Adaptation (LoRA) method to perform low-rank updates on a pretrained ***SAM*** with a small amount of curated high-resolution aerial imagery to map the water extents in the Mackinaw watershed, a HUC-8 in central Illinois. Through our experiments, we show that ***SAS*** is lightweight yet highly effective: it enables efficient fine-tuning on a single consumer-grade GPU while achieving a high IoU of 0.76. This research highlights a generalizable framework for repurposing foundation models in computer vision to support river/stream segmentation. We believe this framework can benefit the accurate and scalable quantification of streambank erosion as assessed by bank migration and width changes over time, a significant source of sediment and nutrient losses in agricultural landscapes, and an important indicator of a variety of aspects of SDG. Code and data will be released upon paper acceptance.

Chat is not available.