Skip to content

linhanwang/SCCNet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Self-Correlation and Cross-Correlation Learning for Few-Shot Remote Sensing Image Semantic Segmentation

Introduction

This is the source code for our paper Self-Correlation and Cross-Correlation Learning for Few-Shot Remote Sensing Image Semantic Segmentation, which is accepted to Sigspatial 2023.

Network Architecture

network

Installation

  • Install PyTorch 2.0.1 and other dependenies
  • Clone this repo
git clone https://github.com/linhanwang/SCCNet.git

Data Preparation

Download remote_sensing.tar.gz from here, unzip and put it under your directory 'SCCNet'.

Train

python train.py  --max_steps 200000 --freeze True --datapath './remote_sensing/iSAID_patches' --img_size 256 --backbone resnet50 --fold 0 --benchmark isaid --lr 9e-4 --bsz 32 --logpath exp_name

The log and checkpoints are stored under directory 'logs'.

Test

python test.py --datapath './remote_sensing/iSAID_patches' --img_size 256 --backbone resnet50 --fold 0 --benchmark isaid --bsz 64 --nshot 1 --load './logs/exp_name/best_model.pt'

We provide a pretrained-model for the above setting. You can download it from here.

The fusion process is implemented in test.py, you can turn it on in test.sh. You can turn it on by setting fuse=True. The option eigen_path is used to indicate the directory of eigen vectors. The process to generate eigen vectors is described in spectral.

Reference

We borrow code from public projects SDM, HSNet, dss.

About

Official pytorch implementation of Self-Correlation and Cross-Correlation Learning for Few-Shot Remote Sensing Image Semantic Segmentation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages