I have a numpy array of shape (66,67,4). When I do np.mean(imarray) it calculates the array mean but takes all channels into consideration. I want to calculate the mean of only channel 1 and channel 3, separately.
I am doing this since I have a .tif file and it contains certain attributes in each band and they are essentially independent from each other so I need to calculate means separately
np.mean(im[...,1])andnp.mean(im[...,3])