Buckets:
JL1-ChangeMambaSCD
ChangeMamba SCD weights trained for the JL1_second setup in SCD-CropLand-HZ.
Files
Base/,Small/,Tiny/— one folder per backbone scale; each holdsbest_model.pthwhen released*/ckpt/*_model.pth— periodic training saves (optional)- You still need VMamba backbone weights on disk for inference (
--pretrained_weight_path); those are separate from this repo (same files as in the training YAMLs)
Quick installation
Clone SCD-CropLand-HZ — it contains
src/ChangeMamba,infer_MambaSCD.py, and dataset notes underdocs/.Create a Python 3.10 environment with CUDA PyTorch, install ChangeMamba deps, and build the selective-scan kernel:
conda create -n mambascd python=3.10 -y && conda activate mambascd
pip install torch==2.1.1 torchvision==0.16.1 --index-url https://download.pytorch.org/whl/cu118
cd src/ChangeMamba && pip install -r requirements.txt
cd kernels/selective_scan && pip install . && cd ../../..
pip install rasterio
- Download this checkpoint tree into the project (paths below assume repo root):
pip install -U huggingface_hub
huggingface-cli download BiliSakura/JL1-ChangeMambaSCD --local-dir models/BiliSakura/JL1-ChangeMambaSCD
- Download the matching VMamba ImageNet checkpoint for your variant (file names must match
--pretrained_weight_path). The training configs use MzeroMiko/VMamba — e.g.vssm_small_0229_ckpt_epoch_238.pthfor Small.
More detail: installation.md in the same repository.
Inference
Inference runs infer_MambaSCD.py. Test data must be in ChangeMamba SCD layout (bi-temporal images + labels; list file of basenames). See docs/dataset.md in SCD-CropLand-HZ.
From the repository root, after export PYTHONPATH=src:${PYTHONPATH}:
VMamba-Small + this repo’s Small weights
python src/ChangeMamba/changedetection/script/infer_MambaSCD.py \
--cfg src/ChangeMamba/changedetection/configs/vssm1/vssm_small_224.yaml \
--pretrained_weight_path models/MzeroMiko/VMamba/vssm_small_0229_ckpt_epoch_238.pth \
--resume models/BiliSakura/JL1-ChangeMambaSCD/Small/best_model.pth \
--dataset JL1_second \
--model_type ChangeMambaSCD \
--test_dataset_path datasets/JL1_second/val \
--test_data_list_path datasets/JL1_second/val.txt \
--infer_size 256 \
--result_saved_path results
Other variants — keep --resume aligned with the folder you use and swap backbone config + pretrained file:
| Variant | --cfg |
Typical --pretrained_weight_path |
|---|---|---|
| Base | .../vssm_base_224.yaml |
.../vssm_base_0229_ckpt_epoch_237.pth |
| Small | .../vssm_small_224.yaml |
.../vssm_small_0229_ckpt_epoch_238.pth |
| Tiny | .../vssm_tiny_224_0229flex.yaml |
.../vssm_tiny_0229_ckpt_epoch_292.pth |
Example --resume paths: models/BiliSakura/JL1-ChangeMambaSCD/Base/best_model.pth, .../Small/best_model.pth, .../Tiny/best_model.pth.
Outputs: RGB PNGs under results/<dataset>/ChangeMambaSCD/change_map_T1/ and .../change_map_T2/ (semantic maps masked by predicted change).
Train / reproduce
From the repository root:
./scripts/train_changemamba_scd.sh configs/train_changemamba_scd_vmamba_base.yaml
Checkpoints are written to model_save_path in the YAML (this folder by default).
Citation
@article{chen2024changemamba,
author={Hongruixuan Chen and Jian Song and Chengxi Han and Junshi Xia and Naoto Yokoya},
journal={IEEE Transactions on Geoscience and Remote Sensing},
title={ChangeMamba: Remote Sensing Change Detection with Spatiotemporal State Space Model},
year={2024},
volume={62},
number={},
pages={1-20},
doi={10.1109/TGRS.2024.3417253}
}
- Total size
- 31.8 GB
- Files
- 23
- Last updated
- Mar 20
- Pre-warmed CDN
- US EU US EU