fix for grayscale images and images which cannot be read by openCV in general