Astronomy Python - Crab Nebula - Combine RGB channel images into One Image
In Astronomy, Image taken by cameras would be based on specific filters(channels)-Red, Green, Blue. Below are the the images taken across 3 channels. Red(Left), Green(Centre), Blue(Right) Original image credit(single image which is not shown here)- Credits: NASA, ESA, J. Hester and A. Loll (Arizona State University) Below is result after combining above 3 channel images Below is the python code used. Original Carb Nebula image is spitted into 3 channels(as shown 3 gray images above) *************************************************** from PIL import Image # Open the red, green, and blue channel images red_channel = Image.open('E:\\astronomy_related\\rbg_one\\red.png') green_channel=Image.open('E:\\astronomy_related\\rbg_one\\green.png') blue_channel =Image.open('E:\\astronomy_related\\rbg_one\\blue.png') # Create a new RGB image result = Image.merge("RGB", (red_channel, green_channel, blue_channel)) # Save the result image result.save('E:\\astr...
Comments
Post a Comment