I created some GOES-16 images where the dark/night side of the visible image is transparent (alpha channel). I used satpy's DayNight Compositor to make the night side of the image transparent, while keeping the day time in gray scale. Unfortunately, using this method has converted the original L (gray) image into an RGBA image.
I tried using PIL to convert the image from RGBA mode to LA mode but it removes the georeferenced data in the GeoTiff.
img = Image.open(filename_of_RGBA).convert('LA')
img.save(new_filename)
How can I keep the georeferenced data while converting from RGBA to LA?