I’m lacking in data and want to train the data in monochrome instead of RGB. But I couldn’t find a way to transform images into monochrome in fastai.
I wish fastai had such a feature. But if there is no such feature now, is there any way to do it with some workaround?
barnacl
(Rekil Prashanth)
2
You can use PIL to this:
from PIL import Image
img = Image.open('image.png').convert('LA')
img.save('greyscale.png')
here are some other ways
1 Like
barnacl
(Rekil Prashanth)
3
Could you explain more ^ ?
cap_rogers
(Venkateshwar Ragavan)
4
Is it possible to reduce the number of channels of an Image while creating the DataBunch object? If so, how?
1 Like
I have too little data to train.
But how can I do it for the whole image? And for transformed images by fastai API.