cvdfoundation / fashionpedia

128 stars 14 forks source link

Some grayscale images in train set? #4

Closed BrandonHanx closed 2 years ago

BrandonHanx commented 2 years ago

Hi, thanks for your great work.

I found there are many gray-scale images in the training set. Is this expected?

like ac7f353fd7481926e8fa9eafed609948.jpg, 7d956f0919f2eab63e481e9321ce2028.jpg and so on

KMnP commented 2 years ago

hey, thanks for the question. Yes that is expected.

BrandonHanx commented 2 years ago

Thanks for your reply.

How do you tackle these grayscale images in the training stage? Just repeat 3 channels for CNN's input?

KMnP commented 2 years ago
from PIL import Image as PILImage
im = PILImage.open(img_dir)
rgb_im = im.convert('RGB')

I converted them to rgb using pillow

BrandonHanx commented 2 years ago

I see. This issue is solved for me. Thanks.