Optical Cloud Removal with Microwave Image Structural Information Fusion and Spatial-Frequency Alignment
This repository provides the official PyTorch implementation of OSFNet, the method proposed in our paper 融合微波图像结构信息的空频对齐光学去云方法.
- Structure-aware SAR guidance. A dedicated SAR branch based on ReAFConv extracts cloud-independent geometric and texture cues while reducing modality interference.
- Decoupled spatial-frequency modeling. SSAB and FSAB model optical spatial context and frequency degradation separately, avoiding premature feature mixing.
- Adaptive spatial-frequency alignment. SF-AlignNet performs correlation matching and adaptive fusion to recover reliable structures under stripe clouds, fragmented clouds, and high cloud coverage.
| Dataset | PSNR (dB) | SSIM | SAM | MAE | ColorLoss |
|---|---|---|---|---|---|
| SMILE-CR | 30.8528 | 0.8451 | - | - | - |
| SEN12MS-CR | 29.0844 | 0.8940 | 7.6636 | 0.02725 | 0.1508 |
The datasets are not redistributed in this repository. Download them from their official pages:
Organize SEN12MS-CR as follows:
SEN12MS-CR/
├── train/
│ ├── s1/
│ ├── s2_cloudfree/
│ ├── s2_cloudy/
│ └── data.csv
├── val/
│ ├── s1/
│ ├── s2_cloudfree/
│ ├── s2_cloudy/
│ └── data.csv
└── test/
├── s1/
├── s2_cloudfree/
├── s2_cloudy/
└── data.csv
Organize SMILE-CR as follows:
SMILE-CR/
├── train/
│ ├── s1/
│ ├── L8_cloudfree/
│ ├── L8_cloudy/
│ └── train_data.csv
├── val/
│ ├── s1/
│ ├── L8_cloudfree/
│ ├── L8_cloudy/
│ └── val_data.csv
└── test/
├── s1/
├── L8_cloudfree/
├── L8_cloudy/
└── test_data.csv
If the SMILE-CR CSV files are unavailable, generate them with:
python create_smile_csv.pyconda create -n osfnet python=3.8
conda activate osfnet
pip install torch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 --index-url https://download.pytorch.org/whl/cu118
pip install -r requirements.txtTrain and evaluate on SEN12MS-CR:
python train_test.pyTrain and evaluate on SMILE-CR:
python train_test_smile.pyEvaluate a trained SMILE-CR model:
python test.py --weight_path /path/to/weight.pthDataset locations, CSV paths, checkpoint directories, and training parameters can be changed through the command-line arguments defined in each script.
The manuscript is currently under review. Citation information will be updated after publication.
For questions or suggestions, please open a GitHub issue.