I am having trouble displaying
RGB FITS files that were captured by my Nikon, using INDI from the Python cli.
Sample code that I have found out on the interwebs don't work very well with 'real' RGB FITS files.
Opening the file and reading the header yields:
Filename: ./M_57_Light_001.fits
No. Name Ver Type Cards Dimensions Format
0 PRIMARY 1 PrimaryHDU 52 (6016, 4016, 3) uint8
The first problem that I hacked my way through was the need to 'reshape' the image data after opening it.
image_data = fits.getdata(image_file)
image_data = image_data.reshape(image_data.shape[2],image_data.shape[1],image_data.shape[0])
After reshaping the data, calling
plt.imshow(image_data,origin='lower')
plt.show()
yields a black rectangle.
(when using any image processing program, stars can be seen in the original image, even without stretching, so the image does have visible data)
Does anyone have an actual, simple example of displaying a DSLR-captured , RGB image in FITS format that was written by INDI?
Thanks in advance!
Dan