Welcome to our step-by-step guide on utilizing the SatlasPretrain dataset for pre-training powerful foundation models on satellite and aerial images. This blog will navigate you through the dataset’s features, model usage, and troubleshooting tips for a seamless experience.
What is SatlasPretrain?
SatlasPretrain is a comprehensive remote sensing image dataset designed to empower AI models. By leveraging satellite and aerial images paired with millions of labels sourced from various datasets like OpenStreetMap and WorldCover, it aims to boost the capabilities of foundation models in interpreting diverse remote sensing scenarios.
Getting Started with the Dataset
The SatlasPretrain dataset is available in tar files located within the dataset folder of the repository. Here’s a quick guide to accessing and using the dataset:
Understanding the Models
The dataset features several model architectures, including Swin Transformer and Resnet. These models are pre-trained on a variety of imagery types:
- Sentinel-2
- Sentinel-1
- Landsat 8
- Aerial imagery (0.5 – 2 mpixel)
Metaphorically speaking, think of the dataset as a library stacked with books (the images) and annotations (the labels). Just as different readers can utilize those books for various purposes, different AI models can leverage this rich dataset for an array of applications—from environmental monitoring to agricultural analysis.
Model Usage and Input Normalization
Once you have the dataset, use the following code to load the models for your specific tasks:
import torch
import torchvision
model = torchvision.models.swin_transformer.swin_v2_b()
full_state_dict = torch.load("satlas-model-v1-highres.pth")
swin_prefix = "backbone."
swin_state_dict = {k[len(swin_prefix):]: v for k, v in full_state_dict.items() if k.startswith(swin_prefix)}
model.load_state_dict(swin_state_dict)
This code is analogous to preparing a meal: you gather several ingredients (your model and state dict), prepare them (load state), and serve (load parameters into the model) to create a delicious dish (your trained model).
Where to Find the Code
The training code and the SatlasPretrain dataset are hosted at GitHub. Interested in the research? The paper will be presented at the International Conference on Computer Vision in October 2023, more details can be found here.
Troubleshooting Common Issues
As with any technical endeavor, you might encounter some challenges. Here are a few troubleshooting ideas:
- Ensure that you have the correct version of dependencies like PyTorch and torchvision.
- If the model fails to load, double-check the file paths and ensure that the model weights are correctly specified.
- Common errors often stem from mismatches in the expected input sizes; confirm your input images match the model requirements.
For more insights, updates, or to collaborate on AI development projects, stay connected with fxis.ai.
Feedback
We welcome any feedback you may have regarding the model or the training data! Please open an issue on the SatlasPretrain GitHub to let us know your thoughts.
At fxis.ai, we believe that such advancements are crucial for the future of AI, as they enable more comprehensive and effective solutions. Our team is continually exploring new methodologies to push the envelope in artificial intelligence, ensuring that our clients benefit from the latest technological innovations.

