My main aim is to produce 1D array out of each image in the 'dengue' folder. For which I used below code to read the file using both PIL and GLOB.
from PIL import Image import glob
image_list = []
for filename in glob.glob('./dengue/*.tiff'):
im=Image.open(filename)
image_list.append(im)
OUTPUT IS -
UnidentifiedImageError: cannot identify image file './dengue/image_2016-09-18.tiff
How to resolve this? The same error showed up for numerous other images.
Or is there any other way I can read each of these tiff images to produce 1D array out of them? Thank you so much for your time.