Seasonal Contrast: Unsupervised Pre-Training from Uncurated Remote Sensing Data

Overview

Seasonal Contrast: Unsupervised Pre-Training from Uncurated Remote Sensing Data

diagram

This is the official PyTorch implementation of the SeCo paper:

@article{manas2021seasonal,
  title={Seasonal Contrast: Unsupervised Pre-Training from Uncurated Remote Sensing Data},
  author={Ma{\~n}as, Oscar and Lacoste, Alexandre and Giro-i-Nieto, Xavier and Vazquez, David and Rodriguez, Pau},
  journal={arXiv preprint arXiv:2103.16607},
  year={2021}
}

Preparation

Install Python dependencies by running:

pip install -r requirements.txt

Data Collection

First, obtain Earth Engine authentication credentials by following the installation instructions.

Then, to collect and download a new SeCo dataset from a random set of Earth locations, run:

python datasets/seco_downloader.py \
  --save_path [folder where data will be downloaded] \
  --num_locations 200000

Unsupervised Pre-training

To do unsupervised pre-training of a ResNet-18 model on the SeCo dataset, run:

python main_pretrain.py \
  --data_dir datasets/seco_1m --data_mode seco \
  --base_encoder resnet18

Transferring to Downstream Tasks

With a pre-trained SeCo model, to train a supervised linear classifier on 10% of the BigEarthNet training set in a 4-GPU machine, run:

python main_bigearthnet.py \
  --gpus 4 --accelerator dp --batch_size 1024 \
  --data_dir datasets/bigearthnet --train_frac 0.1 \
  --backbone_type pretrain --ckpt_path checkpoints/seco_resnet18_1m.ckpt \
  --freeze_backbone --learning_rate 1e-3

To train a supervised linear classifier on EuroSAT from a pre-trained SeCo model, run:

python main_eurosat.py \
  --data_dir datasets/eurosat \
  --backbone_type pretrain --ckpt_path checkpoints/seco_resnet18_1m.ckpt

To train a supervised change detection model on OSCD from a pre-trained SeCo model, run:

python main_oscd.py \
  --data_dir datasets/oscd \
  --backbone_type pretrain --ckpt_path checkpoints/seco_resnet18_1m.ckpt

Datasets

Our collected SeCo datasets can be downloaded as following:

#images RGB preview size link md5
100K 7.3 GB download ebf2d5e03adc6e657f9a69a20ad863e0
~1M 36.3 GB download 187963d852d4d3ce6637743ec3a4bd9e

Pre-trained Models

Our pre-trained SeCo models can be downloaded as following:

dataset architecture link md5
SeCo-100K ResNet-18 download dcf336be31f6c6b0e77dcb6cc958fca8
SeCo-1M ResNet-18 download 53d5c41d0f479bdfd31d6746ad4126db
SeCo-100K ResNet-50 download 9672c303f6334ef816494c13b9d05753
SeCo-1M ResNet-50 download 7b09c54aed33c0c988b425c54f4ef948
Owner
ElementAI
ElementAI
UPSNet: A Unified Panoptic Segmentation Network

UPSNet: A Unified Panoptic Segmentation Network Introduction UPSNet is initially described in a CVPR 2019 oral paper. Disclaimer This repository is te

Uber Research 622 Dec 26, 2022
The coda and data for "Measuring Fine-Grained Domain Relevance of Terms: A Hierarchical Core-Fringe Approach" (ACL '21)

We propose a hierarchical core-fringe learning framework to measure fine-grained domain relevance of terms – the degree that a term is relevant to a broad (e.g., computer science) or narrow (e.g., de

Jie Huang 14 Oct 21, 2022
SegNet-Basic with Keras

SegNet-Basic: What is Segnet? Deep Convolutional Encoder-Decoder Architecture for Semantic Pixel-wise Image Segmentation Segnet = (Encoder + Decoder)

Yad Konrad 81 Jun 30, 2022
Model-based reinforcement learning in TensorFlow

Bellman Website | Twitter | Documentation (latest) What does Bellman do? Bellman is a package for model-based reinforcement learning (MBRL) in Python,

46 Nov 09, 2022
High-quality implementations of standard and SOTA methods on a variety of tasks.

Uncertainty Baselines The goal of Uncertainty Baselines is to provide a template for researchers to build on. The baselines can be a starting point fo

Google 1.1k Dec 30, 2022
Adversarial Robustness Toolbox (ART) - Python Library for Machine Learning Security - Evasion, Poisoning, Extraction, Inference - Red and Blue Teams

Adversarial Robustness Toolbox (ART) is a Python library for Machine Learning Security. ART provides tools that enable developers and researchers to defend and evaluate Machine Learning models and ap

3.4k Jan 04, 2023
GLNet for Memory-Efficient Segmentation of Ultra-High Resolution Images

GLNet for Memory-Efficient Segmentation of Ultra-High Resolution Images Collaborative Global-Local Networks for Memory-Efficient Segmentation of Ultra-

VITA 298 Dec 12, 2022
A PyTorch implementation of "TokenLearner: What Can 8 Learned Tokens Do for Images and Videos?"

TokenLearner: What Can 8 Learned Tokens Do for Images and Videos? Source: Improving Vision Transformer Efficiency and Accuracy by Learning to Tokenize

Caiyong Wang 14 Sep 20, 2022
Rethinking the Importance of Implementation Tricks in Multi-Agent Reinforcement Learning

RIIT Our open-source code for RIIT: Rethinking the Importance of Implementation Tricks in Multi-AgentReinforcement Learning. We implement and standard

405 Jan 06, 2023
Code release for "BoxeR: Box-Attention for 2D and 3D Transformers"

BoxeR By Duy-Kien Nguyen, Jihong Ju, Olaf Booij, Martin R. Oswald, Cees Snoek. This repository is an official implementation of the paper BoxeR: Box-A

Nguyen Duy Kien 111 Dec 07, 2022
Base pretrained models and datasets in pytorch (MNIST, SVHN, CIFAR10, CIFAR100, STL10, AlexNet, VGG16, VGG19, ResNet, Inception, SqueezeNet)

This is a playground for pytorch beginners, which contains predefined models on popular dataset. Currently we support mnist, svhn cifar10, cifar100 st

Aaron Chen 2.4k Dec 28, 2022
Towards Understanding Quality Challenges of the Federated Learning: A First Look from the Lens of Robustness

FL Analysis This repository contains the code and results for the paper "Towards Understanding Quality Challenges of the Federated Learning: A First L

3 Oct 17, 2022
Unsupervised 3D Human Mesh Recovery from Noisy Point Clouds

Unsupervised 3D Human Mesh Recovery from Noisy Point Clouds Xinxin Zuo, Sen Wang, Minglun Gong, Li Cheng Prerequisites We have tested the code on Ubun

41 Dec 12, 2022
Implementation of Google Brain's WaveGrad high-fidelity vocoder

WaveGrad Implementation (PyTorch) of Google Brain's high-fidelity WaveGrad vocoder (paper). First implementation on GitHub with high-quality generatio

Ivan Vovk 363 Dec 27, 2022
This is project is the implementation of the DeepShift: Towards Multiplication-Less Neural Networks paper

DeepShift This is project is the implementation of the DeepShift: Towards Multiplication-Less Neural Networks paper, that aims to replace multiplicati

Mostafa Elhoushi 88 Dec 23, 2022
implementation for paper "ShelfNet for fast semantic segmentation"

ShelfNet-lightweight for paper (ShelfNet for fast semantic segmentation) This repo contains implementation of ShelfNet-lightweight models for real-tim

Juntang Zhuang 252 Sep 16, 2022
Blind Image Super-resolution with Elaborate Degradation Modeling on Noise and Kernel

Blind Image Super-resolution with Elaborate Degradation Modeling on Noise and Kernel This repository is the official PyTorch implementation of BSRDM w

Zongsheng Yue 69 Jan 05, 2023
Codes for paper "Towards Diverse Paragraph Captioning for Untrimmed Videos". CVPR 2021

Towards Diverse Paragraph Captioning for Untrimmed Videos This repository contains PyTorch implementation of our paper Towards Diverse Paragraph Capti

Yuqing Song 61 Oct 11, 2022
공공장소에서 눈만 돌리면 CCTV가 보인다는 말이 과언이 아닐 정도로 CCTV가 우리 생활에 깊숙이 자리 잡았습니다.

ObsCare_Main 소개 공공장소에서 눈만 돌리면 CCTV가 보인다는 말이 과언이 아닐 정도로 CCTV가 우리 생활에 깊숙이 자리 잡았습니다. CCTV의 대수가 급격히 늘어나면서 관리와 효율성 문제와 더불어, 곳곳에 설치된 CCTV를 개별 관제하는 것으로는 응급 상

5 Jul 07, 2022
DALL-Eval: Probing the Reasoning Skills and Social Biases of Text-to-Image Generative Transformers

DALL-Eval: Probing the Reasoning Skills and Social Biases of Text-to-Image Generative Transformers Authors: Jaemin Cho, Abhay Zala, and Mohit Bansal (

Jaemin Cho 98 Dec 15, 2022