Parameter-Efficient Adaptation of Geospatial Foundation Models through Embedding Deflection - ICCV 2025
October 21, 2025 ยท View on GitHub
This repo contains the code to reproduce the experiments conducted in the paper published at ICCV 2025:
Parameter-Efficient Adaptation of Geospatial Foundation Models through Embedding Deflection
Implementation of DEFLECT
DEFLECT is based on three elements:
- an Untangled Patch Embedding (UPE): implemented in patch_embed.py and spectral_indices.py (based on Spyndex),
- an Untangled Attention Module (uAtt): implemented in the UntangledAttention class,
- an embedding deflection mechanism: implemented in adapters.py.
Competing methods
Implemented Parameter-Efficient Finetuning methods are:
- LoRA (ICLR 2021),
- Scaled LoRA (CVPR 2024),
- Norm Tuning (ICLR 2024),
- BitFit (ACL 2022).
Reproducing the experiments
Training
Set config, encoder_config, dataset_config, segmentor_config and augmentation_config and start the training process on single gpu:
torchrun --nnodes=1 --nproc_per_node=1 run.py \
--config configs/run/default.yaml \
--encoder_config configs/foundation_models/prithvi.yaml \
--dataset_config configs/datasets/mados.yaml \
--segmentor_config configs/segmentors/upernet.yaml \
--augmentation_config configs/augmentations/segmentation_default.yaml \
--num_workers 4 --eval_interval 1
--finetune lora
Evaluation
torchrun --nnodes=1 --nproc_per_node=1 run.py --batch_size 1 --eval_dir work-dir/the-folder-where-your-exp-is-saved
All of these parameters can also be set in the run config file.
To use more gpus or nodes, set --nnodes and --nproc_per_node correspondingly, see:
https://pytorch.org/docs/stable/elastic/run.html
To use mixed precision training, specify either --fp16 for float16 and or --bf16 for bfloat16
Citation
@InProceedings{Thoreau_2025_ICCV,
author = {Thoreau, Romain and Marsocci, Valerio and Derksen, Dawa},
title = {Parameter-Efficient Adaptation of Geospatial Foundation Models through Embedding Deflection},
booktitle = {Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV)},
month = {October},
year = {2025},
pages = {9594-9604}
}