You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi @kvos!
First of all, thank you for all your great work maintaining and improving CoastSat.
I was diving into the preprocess_single function and noticed that for Landsat 7 the red band is not pan-sharpened. I also found that for Landsat 8 and Landsat 9 the NIR and SWIR band are not pan-sharpened. I re-read the portion of the coastsat paper that discusses the pan-sharpening process and I can't find anything that mentions why only certain bands for L7,L8, and L9 are being pan-sharpened.. What is the reasoning behind not pan-sharpening the red band and the SWIR band for Landsat 7 as well as not pan-sharpening the NIR and SWIR bands for L8 and L9?
I did some experimentation on a L8 site from Santa Cruz, California and a different L7 site and I found that when all the bands are pan-sharpened the results look much clearer. I posted a few screenshots of the results of pan-sharpening using the original method and pan-sharpening all of the bands below.
# pansharpen Blue, Green, Red for Landsat 8 and 9
elif satname in ["L8", "L9"]:
try:
im_ms_ps = pansharpen(im_ms[:, :, [0, 1, 2]], im_pan, cloud_mask)
except: # if pansharpening fails, keep downsampled bands (for long runs)
print("\npansharpening of image %s failed." % fn[0])
im_ms_ps = im_ms[:, :, [0, 1, 2]]
# add downsampled NIR and SWIR1 bands
im_ms_ps = np.append(im_ms_ps, im_ms[:, :, [3, 4]], axis=2)
im_ms = im_ms_ps.copy()
# the extra image is the 15m panchromatic band
im_extra = im_pan
Results of Pan Sharpening
I ran a few experiments to check what the impact of pan-sharpening different bands of a Landsat 7 and Landsat 8 scene would be. The NIR and SWIR bands look much better after pan-sharpening for L8. The RGB image for L7 looks a little bit different the effect of pan-sharpening the red band is not as dramatic as the results for L8.
Experiment 1 ( the control) pan-sharpens the same bands as coastsat.
L7 - Bands 1,2,3 (Blue, Green, NIR) are pan-sharpened
L8 - Bands 0,1,2 (Red ,Blue, Green) are pan-sharpened
Experiment 2: pan-sharpen the red band for L7 and pan-sharpen the NIR band for L8
L7 - Bands 0,1,2,3 (Red, Blue, Green, NIR) are pan-sharpened
L8 - Bands 0,1,2,3 (Red ,Blue, Green, NIR) are pan-sharpened
Experiment 3: all bands are pan-sharpened
L7 - Bands 0,1,2,3,4 (Red, Blue, Green, NIR,SWIR) are pan-sharpened
L8 - Bands 0,1,2,3,4 (Red ,Blue, Green, NIR,SWIR) are pan-sharpened
Landsat 8 Pan-Sharpened Results
The first figure shows an RGB jpg generated after pan-sharpening.
The second figure shows each band being plotted before and after pan-sharpening each bands.
Landsat 7 Pan-Sharpened Results
The first figure shows an RGB jpg generated after pan-sharpening.
The second figure shows each band being plotted before and after pan-sharpening each bands.
The text was updated successfully, but these errors were encountered:
Hi @kvos!
First of all, thank you for all your great work maintaining and improving CoastSat.
I was diving into the
preprocess_single
function and noticed that for Landsat 7 the red band is not pan-sharpened. I also found that for Landsat 8 and Landsat 9 the NIR and SWIR band are not pan-sharpened. I re-read the portion of the coastsat paper that discusses the pan-sharpening process and I can't find anything that mentions why only certain bands for L7,L8, and L9 are being pan-sharpened.. What is the reasoning behind not pan-sharpening the red band and the SWIR band for Landsat 7 as well as not pan-sharpening the NIR and SWIR bands for L8 and L9?I did some experimentation on a L8 site from Santa Cruz, California and a different L7 site and I found that when all the bands are pan-sharpened the results look much clearer. I posted a few screenshots of the results of pan-sharpening using the original method and pan-sharpening all of the bands below.
Snippet of preprocess single function that pan-sharpens L7 bands:
Snippet of preprocess single function that pan-sharpens L8 bands:
Results of Pan Sharpening
I ran a few experiments to check what the impact of pan-sharpening different bands of a Landsat 7 and Landsat 8 scene would be. The NIR and SWIR bands look much better after pan-sharpening for L8. The RGB image for L7 looks a little bit different the effect of pan-sharpening the red band is not as dramatic as the results for L8.
Experiment 1 ( the control) pan-sharpens the same bands as coastsat.
L7 - Bands 1,2,3 (Blue, Green, NIR) are pan-sharpened
L8 - Bands 0,1,2 (Red ,Blue, Green) are pan-sharpened
Experiment 2: pan-sharpen the red band for L7 and pan-sharpen the NIR band for L8
L7 - Bands 0,1,2,3 (Red, Blue, Green, NIR) are pan-sharpened
L8 - Bands 0,1,2,3 (Red ,Blue, Green, NIR) are pan-sharpened
Experiment 3: all bands are pan-sharpened
L7 - Bands 0,1,2,3,4 (Red, Blue, Green, NIR,SWIR) are pan-sharpened
L8 - Bands 0,1,2,3,4 (Red ,Blue, Green, NIR,SWIR) are pan-sharpened
Landsat 8 Pan-Sharpened Results
Landsat 7 Pan-Sharpened Results
The text was updated successfully, but these errors were encountered: