Skip to content

This is the repository for "A Segment Anything Model based weaky supervised learning method for crop mapping using Sentinel-2 time series images".

Notifications You must be signed in to change notification settings

Nick0317Sun/SAMWS

Repository files navigation

SAMWS

This is the repository for "A Segment Anything Model based weakly supervised learning method for crop mapping using Sentinel-2 time series images".

Finetuning with adapters

Download SAM checkpoint, we used ViT-B SAM model.

The main finetuning code is in adapter_finetune.py. Some example data is provided in the repository.

Generating pseudo labels

The codes of generating pseudo labels by different weak annotations lie in pseudoLabels_generate_XXX.py. Our image classification model--attention-based U-Net is in cls_model directory.

Training a segmentation model

The segmentation model this study uses is U-TAE.

Citation

@article{sun2024segment,
  title={A Segment Anything Model based weakly supervised learning method for crop mapping using Sentinel-2 time series images},
  author={Sun, Jialin and Yan, Shuai and Yao, Xiaochuang and Gao, Bingbo and Yang, Jianyu},
  journal={International Journal of Applied Earth Observation and Geoinformation},
  volume={133},
  pages={104085},
  year={2024},
  publisher={Elsevier}
}

Acknowledgement

Spectial thanks to scholars from Meta and Junde Wu, as well as his fellows, for their implementation of adapters in SAM.

About

This is the repository for "A Segment Anything Model based weaky supervised learning method for crop mapping using Sentinel-2 time series images".

Resources

Stars

Watchers

Forks

Languages