Knowledge-Guided Floodwater Level Reasoning for Cloud-Edge Collaborative Monitoring
Authors: Zhengshu Zhou, Shaoyu Wang, Ziyi Geng, Lu Tao, Qian Long
Organizations: College of Artificial Intelligence, Tianjin University of Science and Technology, Tianjin 300457, China · School of Resource and Environmental Sciences, Wuhan University, Wuhan 430079, China
Frequent urban floodwater poses a serious threat to the safety and efficiency of intelligent transportation systems. Existing vision-based methods for floodwater level detection face two main limitations. First, the lack of explicit reasoning leads to poor detection performance and little interpretability. Second, these methods struggle to generalize to the complex and varied real-world road scenes seen from different viewpoints. To address this, we reformulate the task as an explicit visual reasoning problem and propose HydroReasoner, a floodwater level reasoning framework designed for cloud-edge collaboration. HydroReasoner builds on Qwen2.5-VL and is trained with Group Relative Policy Optimization. To address the scarcity of reasoning process annotations, we build a floodwater domain knowledge graph HydroKG and design a novel KG path reward. Through deterministic graph traversal over HydroKG, this reward supervises the model's reasoning process at a fine granularity, which improves both reasoning and generalization. For edge deployment, we apply 4-bit quantization to the model, cutting GPU memory usage by 57% and inference latency by 43% while out-of-domain accuracy drops by only 0.2 percentage points. We also propose a confidence-based cloud-edge routing mechanism, which improves system safety and eases the computational load on the cloud. In addition, we build HydroLevel, a floodwater benchmark dataset of 3,000 images, for training and evaluating the model. Experimental results show that HydroReasoner achieves detection accuracy 4.0 and 13.6 percentage points higher than conventional vision baselines in the in-domain and out-of-domain evaluations respectively, with performance dropping by only 4.4 percentage points out of domain.
Figures & tables
Fig. 1: Overview of the proposed collaborative edge-cloud traffic monitoring network. The system leverages 5G technology to aggregate multi-source floodwater imagery from Unmanned Aerial Vehicles (UAVs), vehicles (dashcams), and Roadside Units (RSUs). These diverse data streams, captured from heterogeneous viewpoints, are transmitted to the cloud server or processed locally, where the proposed HydroReasoner framework performs efficient and interpretable floodwater level reasoning.
Fig. 2: The overall framework of HydroReasoner. The pipeline comprises three stages: (I) Reasoning Path Generation: the policy model performs explicit reasoning on the input floodwater image and outputs a structured reasoning path. (II) HydroKG Path Verification: the reasoning path is parsed into candidate triples and verified against HydroKG for structural completeness and consistency with domain grading rules. (III) Reward Shaping and GRPO Update: the verification result, together with format and accuracy signals, forms a composite reward that drives the policy update.
Fig. 3: Sample images from the HydroLevel dataset. The dataset comprises floodwater images across multiple views, diverse scenes, and varying severity levels. The viewing perspective is annotated in the bottom-right corner of each image: CCTV (Closed-Circuit Television) denotes a surveillance view, while UAV denotes an Unmanned Aerial Vehicle view. In selected images, red bounding boxes highlight key reference objects used for assessing the floodwater level, accompanied by the classification criteria.
Dataset Subset
Domain
Content
Class Distribution
Total
L1
L2
L3
L4
HydroLevel-Train
Source
⟨I,y⟩
400
400
400
400
1,600
HydroLevel-Val
Source
⟨I,y⟩
50
50
50
50
200
HydroLevel-VQA
Source
⟨I,CoT,y⟩
450
450
450
450
1,800
HydroLevel-InD
Source
⟨I,y⟩
50
50
50
50
200
HydroLevel-OutD
Target
⟨I,y⟩
250
250
250
250
1,000
TABLE I: Detailed specifications of the HydroLevel Benchmark.
Fig. 4: Statistical distributions of visual attributes in the HydroLevel dataset. The subfigures illustrate the dataset’s diversity in (a) road scenes, (b) reasoning referents (e.g., vehicles and pedestrians), (c) capture viewpoints, and (d) illumination conditions.
Model Name
4-class Metrics
2-class Metrics
Param.
Modality
Acc
Prec.
Rec.
F1
Acc
F1
HydroReasoner (Ours)
0.920
0.9319
0.920
0.9216
0.975
0.975
7B
VL
DenseNet
0.875
0.8763
0.875
0.8751
0.945
0.945
20M
Vision
EfficientNet
0.880
0.8892
0.880
0.8788
0.955
0.956
12M
Vision
ViT-base
0.880
0.8898
0.880
0.8818
0.935
0.936
86M
Vision
Swin Transformer
0.870
0.8757
0.870
0.8709
0.935
0.9341
88M
Vision
TABLE II: Comparison of Model Performance on In-domain Data.
Fig. 5: Comparison of fine-grained confusion matrices on the in-domain and out-of-domain test sets. We select representative models from each category of baselines, including HydroReasoner, SFT variant, Gemini 3, and ViT-Base, to compare their performance differences on the fine-grained four-class task.
Model Name
4-class Metrics
2-class Metrics
Param.
Modality
Acc
Prec.
Rec.
F1
Acc
F1
HydroReasoner (Ours)
0.876
0.8811
0.876
0.8775
0.955
0.9549
7B
VL
DenseNet
0.735
0.7444
0.735
0.7319
0.858
0.8570
20M
Vision
EfficientNet
0.726
0.7292
0.726
0.7254
0.860
0.8596
12M
Vision
ViT-base
0.740
0.7527
0.740
0.7381
0.823
0.8223
86M
Vision
Swin Transformer
0.704
0.7075
0.704
0.7012
0.805
0.8042
88M
Vision
TABLE III: Comparison of Model Performance on Out-of-domain Data.
Fig. 6: Generalization gap analysis between in-domain and out-of-domain settings. The figure shows the performance differences between HydroReasoner and models trained with supervised learning strategies, including conventional image classification models and SFT variants, on in-domain and out-of-domain evaluations. Hollow and solid markers indicate performance on the in-domain and out-of-domain test sets, respectively, and the length of the connecting line represents the performance gap between the two evaluations.
Fig. 7: Comprehensive performance analysis of HydroReasoner versus baseline models. The subfigures illustrate: (a) the relationship between in-domain/out-of-domain four-class accuracy and safety; (b) the relationship among parameter scale, generalization gap, and accuracy; (c) the trade-offs among coarse-/fine-grained task performance, safety, and model size; and (d) an overall assessment that integrates out-of-domain accuracy, safety, and robustness (note that all metrics in the figure are normalized).
Configuration
Reasoning Quality
Accuracy
SC
LC
OutD 4-class
w/o KG path reward
0.782
0.923
0.843
w/o sstruct
0.828
0.956
0.851
w/o spred , sgt
0.979
0.943
0.863
w/o sbranch , samb
0.978
0.980
0.870
Full (Ours)
0.983
0.991
0.876
TABLE IV: Component-Level Ablation of the KG Path Reward.
Configuration
Inference Time
Memory
Avg. Power
4-class Accuracy
InD
OutD
BF16, K=1
7.6 s
16.7 GB
37 W
0.920
0.876
INT4, K=1
4.3 s
7.1 GB
26 W
0.920
0.874
INT4, K=3
6.8 s
7.3 GB
30 W
0.920
0.874
TABLE V: Ablation Study on Quantization Strategy
Model Precision
Format Validity
KG Path Validity
Sampling Consistency
Path-Alignment
InD
OutD
InD
OutD
InD
OutD
InD
OutD
BF16
1.000
0.995
0.995
0.978
1.000
0.980
0.900
0.855
INT4
1.000
0.995
0.990
0.970
1.000
0.980
0.900
0.850
TABLE VI: Effect of Quantization on Structured Output Quality.
Fig. 8: Reasoning processes and final conclusions of HydroReasoner, Qwen2.5-VL-Instruct-72B, Gemini 3 and the SFT variant of HydroReasoner on two typical floodwater scenarios (both Level 4). The content contained within the < think ></ think > tags represents the reasoning process, in which the red-colored text indicates the key judgment basis. The content contained within < answer ></ answer > represents the final conclusion.
Prompt Strategy
In-domain
Out-of-domain
4-class Acc
2-class Acc
4-class Acc
2-class Acc
w/o Reasoning (Direct Output)
0.890
0.975
0.845
0.933
w/ Reasoning (Ours)
0.920
0.975
0.876
0.955
TABLE VII: Ablation Study on Reasoning Strategy.
Metric
In-domain
Out-of-domain
Edge Accuracy (4-class)
0.920
0.876
Cloud-Routing Rate
0.150
0.253
Edge-Accepted Accuracy
0.976
0.969
System-Level High-Risk Recall
1.000
1.000
High-Risk Miss Interception Rate
–
1.000
Error Recall
0.750
0.815
TABLE VIII: Evaluation of the Cloud–Edge Collaborative Inference.
Metric
In-domain
Out-of-domain
Reference-Object Accuracy
0.980
0.930
Waterline-Evidence Accuracy
0.900
0.855
Path-Alignment Accuracy
0.900
0.855
Classification Accuracy (ref.)
0.920
0.885
TABLE IX: Reasoning Grounding Evaluation.
Layer
Node types
Relation
Target layer
Anchor
Physical reference (6)
has_wl_rel.
Evidence
No reliable reference (1)
has_env_cue
Evidence
Surface-state start (2)
has_surf_st.
Evidence
Evidence
Waterline relation (18)
indicates
Depth
Environmental cue (5)
indicates
Depth
Surface state (3)
supports
Level
TABLE X: The Schema of HydroKG.
Head
Relation
Tail
Head
Relation
Tail
Level 1 (short chain): road-surface state
Reference object: e-bike
road_surface
has_surf_st.
dry_road_surface
ebike
has_wl_rel.
below_footboard
road_surface
has_surf_st.
slight_wetness
ebike
has_wl_rel.
footboard~half_wheel
natural_water_region
has_surf_st.
natural_water_body
ebike
has_wl_rel.
above_half_wheel
dry_road_surface
supports
level_1
below_footboard
indicates
depth_lt_15cm
slight_wetness
supports
level_1
footboard~half_wheel
indicates
depth_15_30cm
TABLE XI: The complete edge set of HydroKG
Zhengshu Zhou received the B.E. degree in software engineering from Tianjin University, Tianjin China, in 2013. He received the Master and Ph.D. degree in informatics from Nagoya University, Nagoya Japan, in 2020 and 2022, respectively. He is currently an Associate Professor with the College of Artificial Intelligence, Tianjin University of Science & Technology (TUST). Previously, he was a system engineer with the Japanese automotive industry. And he was a researcher at Hitachi Yokohama Research Laboratory, Yokohama, Japan. He has published over 30 academic papers, including in top journals in the fields of Intelligent transportation and reliability engineering, such as IEEE TITS, IEEE TVT, IEEE TNSM and RESS. He has also led several research projects related to intelligent driving and computer vision. His research interests mainly include software engineering, autonomous driving, and high-precision dynamic map.
Table 20
Shaoyu Wang received the B.E. degree in computer science and technology from North China Institute of Aerospace Engineering, Langfang, China, in 2024. He is currently pursuing the M.S. degree with Tianjin University of Science and Technology, Tianjin, China. His current research interests include deep learning and autonomous driving.
Table 21
Ziyi Geng received the B.E. degree in software engineering from Hebei University of Economics and Business, Shijiazhuang, China, in 2024. He is currently pursuing the M.S. degree with Tianjin University of Science and Technology, Tianjin, China. His current research interests include autonomous driving and software engineering.
Table 22
Lu Tao is currently a tenure-track associate professor at Wuhan University. He received his B.S. and M.E. degrees in Geographic Information Systems and Navigation, Guidance, and Control from Wuhan University in 2014 and 2017, respectively. He obtained his Ph.D. degree in Informatics from Nagoya University in 2023, and was then a researcher at the Institute of Innovation for Future Society from 2023 to 2024. His research interests include vehicle motion prediction, sensor fusion, high-definition maps, dynamic maps, edge and cloud computing, and connected autonomous vehicles.
Table 23
Qian Long received the B.S. and Ph.D. degrees from the University of Science and Technology of China, Hefei, China, in 2000 and 2007 respectively. He was a faculty member at the Department of Precision Machinery and Precision Instrumentation of the University of Science and Technology of China until 2015. He has worked as a visiting scientist at Brookhaven National Laboratory, Upton, USA (2009-2010), as a research associate at the University of Texas at Brownsville, Brownsville, USA (2010-2011), as a postdoctoral fellow at the Research Center for Smart Vehicles, Toyota Technological Institute, Nagoya, Japan (2012-2015), as a researcher at Nippon Soken, Inc., Nishio, Japan (2015-2016), and as a professor at Yunnan Observatories, Chinese Academy of Sciences, Kunming, China (2016-2023). Currently, he is a professor at the College of Artificial Intelligence, Tianjin University of Science & Technology, Tianjin, China. His research interests include computer vision, machine learning, autonomous driving, and artificial intelligence.
Civil and Environmental Engineering Wayne State University 5050 Anthony Wayne Drive, Detroit, MI, USA, 48202 · Civil and Environmental Engineering Institute for AI and Data Science (AIDaS) Wayne State University 5050 Anthony Wayne Drive, Detroit, MI, USA, 48202
Department of Civil & Environmental Engineering Wayne State University Detroit, MI, USA · Department of Civil & Environmental Engineering Institute for AI and Data Science (AIDaS) Wayne State University Detroit, MI, USA · Department of Computer Science, Institute for AI and Data Science (AIDaS) Wayne State University Detroit, MI, USA