I have nii.gz volume and I need to display it as one image. I could display one slice as shown below.
mri_file = '/tmp/out_img/case0001_gt.nii.gz'
img = nib.load(mri_file)
mg_data = img.get_fdata()
mid_slice_x = img_data[ :, :,119]
plt.imshow(mid_slice_x.T, cmap='gray', origin='lower')
plt.xlabel('First axis')
plt.ylabel('Second axis')
plt.colorbar(label='Signal intensity')
plt.show()
But I need to display the whole volume as one image with different color maps as show below.