Jing Shen , Yawen He , Jian Peng , Tang Liu , Chenghu Zhou
{"title":"An open-source data-driven automatic road extraction framework for diverse farmland application scenarios","authors":"Jing Shen , Yawen He , Jian Peng , Tang Liu , Chenghu Zhou","doi":"10.1016/j.compag.2025.110330","DOIUrl":null,"url":null,"abstract":"<div><div>The narrow contours of farmland roads, lack of clear boundary features with surrounding objects, and the complexity and variability of features limit the applicability of existing supervised extraction algorithms. Meanwhile, visual segmentation models represented by SAM (Segment Anything Model) can achieve zero-shot generalization with appropriate prompts but struggle to capture linear object effectively. This study introduces OSAM (OpenStreetMap SAM), which fine-tunes SAM using historical open-source datasets to enhance its ability to detect linear features. Then the OSAM framework dynamically generates prompts from the open geographic database OpenStreetMap to activate SAM, enabling autonomous detection of farmland roads without the need for additional manual annotations or assisted interactions. Experiments demonstrate that OSAM performs exceptionally well in scenarios with sparse farmland road distributions and delivers robust results even with limited training data. Specifically, OSAM achieves a F1 of 71.91 % and an IoU of 58.53 % when trained on the full dataset, significantly outperforming DLinkNet (IoU: 56.42 %) and SegFormer (IoU: 41.65 %). Even with only 1 % of the original training samples, OSAM maintains robust performance (F1: 62.26 %, IoU: 47.02 %), whereas supervised learning methods such as SegFormer, SIINet, and UNet suffer significant performance degradation under extreme data constraints. Furthermore, evaluations on remote sensing images with varying data distributions, spatial resolutions, and agricultural environments confirm that OSAM achieves high extraction accuracy and strong generalization ability. This framework significantly reduces reliance on large, well-balanced labeled datasets while maintaining high accuracy, making farmland road extraction more efficient and cost-effective in diverse scenarios.</div></div>","PeriodicalId":50627,"journal":{"name":"Computers and Electronics in Agriculture","volume":"235 ","pages":"Article 110330"},"PeriodicalIF":7.7000,"publicationDate":"2025-03-26","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Computers and Electronics in Agriculture","FirstCategoryId":"97","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S0168169925004363","RegionNum":1,"RegionCategory":"农林科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q1","JCRName":"AGRICULTURE, MULTIDISCIPLINARY","Score":null,"Total":0}
引用次数: 0
Abstract
The narrow contours of farmland roads, lack of clear boundary features with surrounding objects, and the complexity and variability of features limit the applicability of existing supervised extraction algorithms. Meanwhile, visual segmentation models represented by SAM (Segment Anything Model) can achieve zero-shot generalization with appropriate prompts but struggle to capture linear object effectively. This study introduces OSAM (OpenStreetMap SAM), which fine-tunes SAM using historical open-source datasets to enhance its ability to detect linear features. Then the OSAM framework dynamically generates prompts from the open geographic database OpenStreetMap to activate SAM, enabling autonomous detection of farmland roads without the need for additional manual annotations or assisted interactions. Experiments demonstrate that OSAM performs exceptionally well in scenarios with sparse farmland road distributions and delivers robust results even with limited training data. Specifically, OSAM achieves a F1 of 71.91 % and an IoU of 58.53 % when trained on the full dataset, significantly outperforming DLinkNet (IoU: 56.42 %) and SegFormer (IoU: 41.65 %). Even with only 1 % of the original training samples, OSAM maintains robust performance (F1: 62.26 %, IoU: 47.02 %), whereas supervised learning methods such as SegFormer, SIINet, and UNet suffer significant performance degradation under extreme data constraints. Furthermore, evaluations on remote sensing images with varying data distributions, spatial resolutions, and agricultural environments confirm that OSAM achieves high extraction accuracy and strong generalization ability. This framework significantly reduces reliance on large, well-balanced labeled datasets while maintaining high accuracy, making farmland road extraction more efficient and cost-effective in diverse scenarios.
期刊介绍:
Computers and Electronics in Agriculture provides international coverage of advancements in computer hardware, software, electronic instrumentation, and control systems applied to agricultural challenges. Encompassing agronomy, horticulture, forestry, aquaculture, and animal farming, the journal publishes original papers, reviews, and applications notes. It explores the use of computers and electronics in plant or animal agricultural production, covering topics like agricultural soils, water, pests, controlled environments, and waste. The scope extends to on-farm post-harvest operations and relevant technologies, including artificial intelligence, sensors, machine vision, robotics, networking, and simulation modeling. Its companion journal, Smart Agricultural Technology, continues the focus on smart applications in production agriculture.