Panchromatic Sharpening
Guide by Aaron Zuspan
Panchromatic sharpening is simple in eemont!
Before anything, let’s import our modules and authenticate in Google Earth Engine:
import ee, eemont
ee.Authenticate()
ee.Initialize()
Now, we are ready to go!
Overview
The eemont package extends the ee.Image and ee.ImageCollection classes with the method panSharpen():
ee.Image
|
Apply panchromatic sharpening to the Image. |
ee.ImageCollection
|
Apply panchromatic sharpening to each Image in the Image Collection. |
Supported Platforms
Pansharpening is supported for the following platforms:
Landsat Missions
USGS Landsat 8 Collection 1 Tier 1 and Real-Time data TOA Reflectance
USGS Landsat 7 Collection 1 Tier 1 and Real-Time data TOA Reflectance
Warning
Surface Reflectance products do not contain panchromatic bands and do not support pan-sharpening.
Algorithms
The panSharpen method can be run using a variety of different algorithms by setting the method argument. The following sharpening algorithms are supported by eemont:
Method |
Name |
kwargs |
|---|---|---|
|
Smoothing-Filter Based Intensity Modulation |
No |
|
High-Pass Filter Addition |
No |
|
Principal Component Substitution |
Yes |
|
Simple Mean |
No |
See also
Some algorithms take additional keyword arguments (kwargs) such as maxPixels, geometry, or
bestEffort. These are passed to ee.Image.reduceRegion. More information on how to set these arguments
can be found here.
Usage
Let’s load a supported image from Landsat 8:
img = ee.Image("LANDSAT/LC08/C01/T1_TOA/LC08_047027_20160819")
And sharpen it using the panSharpen method with the default SFIM algorithm.
sharp = img.panSharpen()
Easy as that!
We can also try sharpening with a different algorithm. Remember that some algorirthms take additional keyword arguments.
Here, we’ll specify maxPixels to avoid pixel limitations with the PCS algorithm.
sharp = img.panSharpen(method="PCS", maxPixels=1e13)
Pan-sharpening image collections is identical to sharpening images:
imgCollection = ee.ImageCollection("LANDSAT/LC08/C01/T1_TOA")
sharpCollection = imgCollection.panSharpen()
Quality Assessment
Quality assessment (QA) metrics can be calculated by the panSharpen method to measure how much spectral distortion
was introduced by sharpening and to compare different sharpening algorithms. eemont supports the following QA metrics:
QA |
Name |
Ideal Value |
Mode |
|---|---|---|---|
|
Mean Squared Error |
0 |
Band |
|
Root-Mean Squared Error |
0 |
Band |
|
Relative Average Spectral Error |
0 |
Image |
|
Dimensionless Global Relative Error of Synthesis |
0 |
Image |
|
Difference in Variance |
0 |
Band |
|
Bias |
0 |
Band |
|
Correlation Coefficient |
1 |
Band |
|
Change in mean luminance |
1 |
Band |
|
Change in mean contrast |
1 |
Band |
|
Universal Image Quality Index |
1 |
Band |
Note
Some metrics are calculated image-wise and others are calculated band-wise. Image-wise metrics return one value for the entire image while band-wise metrics return one value for each band.
QA metrics are calculated by passing a list of one or more metrics to the qa argument of the panSharpen
method. Below, we’ll calculate RASE and UIQI while sharpening an image.
metrics = ["RASE", "UIQI"]
img = ee.Image("LANDSAT/LC08/C01/T1_TOA/LC08_047027_20160819")
sharp = img.panSharpen(qa=metrics, maxPixels=1e13)
See also
All QA metrics take additional keyword arguments (kwargs) such as maxPixels, geometry, or
bestEffort. These are passed to ee.Image.reduceRegion. More information can be found here.
Calculated QA metrics are set as properties of the sharpened image and can be retrieved with the get method.
QA property names use the format eemont:{QA}.
sharp.get("eemont:RASE").getInfo()