To start this tutorial, you need to access Google Colab (https://colab.research.google.com/), which is basically a free Jupyter Notebook environment that runs entirely in the cloud.
You’ll also need to create a folder in your Google Drive beforehand where the results will be saved. I named mine Sentinel2_1m, but you can name it whatever you want—the important thing is that the folder already exists before executing the code.
Setting up Google Colab
There are two ways to connect your Google Drive with Colab. The first, which I find more practical, is simply clicking the folder icon on the left sidebar (Files, you need to wait a moment until the options appear) and then pressing the Mount Drive button.
The second way is to execute this code in a cell:
from google.colab import drive
drive.mount('/content/drive')
Both options do exactly the same thing, so use whichever is more comfortable for you. The system will ask for authorization to access your Drive—just follow the instructions and accept the permissions.
Now comes something important to prevent the processing from taking forever. You need to activate a GPU in the runtime environment. Look at the bottom right corner of your notebook, where you’ll see something like “Python 3” with a chip icon. Click there and select Change runtime type. A window will open where you should look for Hardware accelerator and select T4 GPU. Save the changes and the notebook will automatically restart with the new configuration.
Checking image availability
Before jumping into running code, I recommend verifying that Sentinel-2 images are available for your area of interest and the date you need. Go to https://apps.sentinel-hub.com/eo-browser/ and search for your location. Ideally, find images with very little cloud cover because that will directly affect the quality of the final result. If your date has many clouds, it’s better to look for another nearby date with better conditions.
Running the processing
Now comes the good part. Copy this code into a new cell in your notebook (you can do it in one or several code cells) and execute it:
# Link the Google Drive folder where results will be saved
!ln -s /content/drive/MyDrive/Sentinel2_1m /content/output
# Install the S2DR3 package for Sentinel-2 image processing
!pip -q install https://storage.googleapis.com/0x7ff601307fa5/s2dr3-20250905.1-cp312-cp312-linux_x86_64.whl
import s2dr3.inferutils
# Coordinates for Loja, Ecuador (longitude, latitude)
lonlat = (-79.203, -4.008)
# Date of the Sentinel-2 image to process
date = '2024-08-23'
# Process the image and generate 1m resolution products
s2dr3.inferutils.test(lonlat, date)
Remember to change the path in the first line if your folder has a different name. The script will link your Drive folder with the output directory, install the necessary dependencies, and begin processing. Depending on the area size, this can take several minutes, so be patient.
Processing limitations
Something important you should know is that the model processes a 4×4 km area around the coordinates you provide. This means if you need to cover larger surfaces, you’ll have to make multiple runs with different coordinates or request access to the full API which will allow you to process much larger areas.
Generated results
When processing finishes, you’ll find eight TIF files in your Drive folder. Two versions of each type are generated: one with original resolution (S2L2A) and another enhanced to 10 meters (S2L2Ax10). I recommend downloading the larger MS.tif file because it contains the complete multispectral image with all 10 bands (B02, B03, B04, B05, B06, B07, B08, B8A, B11, B12).
The nice thing about these files is that when you open them in ArcGIS Pro or QGIS they’re already georeferenced, so you can start working with them immediately without needing any geometric correction. You’ll also find the TCI.tif file which is a true color RGB composition, perfect for quick visualization. The NDVI.tif shows you the vegetation index in pseudocolor, very useful if you work with agricultural or vegetation cover topics. Finally, there’s the IRP.tif which is an infrared composition in pseudocolor.
Customizing for other locations
If you want to process images from another city or region, all you need to do is change the coordinates in the lonlat variable. Be careful with the format because it’s (longitude, latitude)—many people get confused because they usually write it backwards. You can also adjust the date according to what you need, just make sure images are available for that date on Sentinel Hub.
Advanced access
This technology has been developed by Gamma Earth (https://gamma.earth/). The version we’re using here is free and is intended primarily for testing, validation, and academic use. If you need to process larger areas, have greater processing capacity, or access additional functionalities, you can request access to their full API through Request API Access on their website.

