To address the challenges of missing fine-grained objects, blurred boundaries, and the suppression of shallow details by deep semantic features during cross-scale fusion in traffic scene semantic segmentation, this paper proposes a discrepancy-guided semantic segmentation method with boundary detail enhancement. First, to improve the semantic completeness of fine-grained regions, a Gated Collaborative Context Module (GCCM) is introduced between the encoder and decoder. By leveraging gating-guided channel selection and multi-scale contextual modeling, GCCM adaptively captures semantic dependencies across different scales. Second, to alleviate boundary ambiguity and detail loss, a Frequency–Edge Guided Enhancement Module (FEGE) is designed in the decoder. This module explicitly models low-frequency structural information and high-frequency edge components via frequency decomposition, and further enhances high-frequency details using the Scharr operator and lightweight convolution, thereby improving the structural representation of object contours and boundary regions. Furthermore, to mitigate the suppression of shallow details during cross-scale feature fusion, a Discrepancy-aware Pixel-Adaptive Gating Fusion module (D-PagFM) is proposed. By jointly modeling feature similarity and local discrepancy, the module adaptively regulates pixel-wise fusion, enhancing detail integration in structurally consistent regions while suppressing misleading fusion in inconsistent regions, thereby improving the robustness of feature fusion and boundary consistency. Experimental results on the Cityscapes and CamVid datasets demonstrate that the proposed method achieves mIoU scores of 80.08% and 82.97%, respectively. Moreover, it shows more significant improvements in boundary-sensitive fine-grained categories such as road boundaries, poles, and traffic signs, indicating its effectiveness and application potential for high-precision semantic segmentation in traffic scenes.
Yu et al. (Tue,) studied this question.