TreB1eN / InsightFace_Pytorch

Pytorch0.4.1 codes for InsightFace
MIT License
1.74k stars 423 forks source link

something strange when unpacking dataset #75

Closed Walstruzz closed 5 years ago

Walstruzz commented 5 years ago

I download CASIA-Webface (10K ids/0.5M images) from the original post

In script data_pipe.py, line 96, the image is saved by PIL.Image,which encoding image to RGB. I check the result after running prepare_data.py, most of the images are red.

Obviously, modify img = Image.fromarray(img) to img = Image.fromarray(img[:, :, ::-1]) would fix this problem, but I want to know if you design it deliberately, e.g., for post-processing or something else...

Walstruzz commented 5 years ago
Walstruzz commented 5 years ago

I had already checked the images in faces_emore/cfp_fp.bin. The format of the image saved in this matrix is indeed RGB.

niezhongliang commented 4 years ago

I had already checked the images in faces_emore/cfp_fp.bin. The format of the image saved in this matrix is indeed RGB.

thanks, I have met the same problem. Got solved by your tip.