andrewhou1 / GeomConsistentFR

Official Code for Face Relighting with Geometrically Consistent Shadows (CVPR 2022)
https://openaccess.thecvf.com/content/CVPR2022/html/Hou_Face_Relighting_With_Geometrically_Consistent_Shadows_CVPR_2022_paper.html
MIT License
114 stars 17 forks source link

Can you release CelebA-Cropped data?? #4

Closed iseunghoon closed 1 year ago

iseunghoon commented 1 year ago

Hello, thank you for your work. I tried to run recrop_CelebA-HQ_images.py but, some image files failed to detect face region so raised the error at line
"assert img.shape[0] == img.shape[1] == 256" I think your code cannot process exception cases. So can you release cropped face data ??

andrewhou1 commented 1 year ago

Thanks for your interest in our work! Unfortunately, due to the CelebA-HQ license I cannot release the cropped images directly. However, you can find which images will not have cropping errors based on which images have corresponding masks, depth maps, etc in our released training data found in: https://drive.google.com/file/d/1Jh4a5zvx92NRjC5E_MyaKMbFymx2Iw9E/view?usp=sharing

All of those images were able to be cropped and used for training. You can simply choose one of the folders (e.g. mask folder) and crop any CelebA-HQ images that have a corresponding mask (mask name is based on the original image's ID).

Another option is to print out the name and index of each image you are cropping so that you know where it crashes. You can then easily resume cropping at the image after the image that failed.

If both of these solutions are too tedious, I can provide a list of training image names in a text file if needed and the cropping code won't crash for any of those images.

iseunghoon commented 1 year ago

Thank you for kind reply. I followed your manual and run image list in albedo_grayscale folder. I found 15696.jpg, 18332.jpg two images that failed to detect face region. Can you check it??

andrewhou1 commented 1 year ago

I see, so those two images did not fail when I ran the cropping code. I guess it could be a difference in the face alignment package version or some other related package. That is ok, if only those two images failed then we can just adjust the training code if you were planning to train. Any dimension that was originally 29890 can just be changed to 29888. Also simply remove those two image IDs from the depth map, mask, albedo, and lighting directories. Just to make sure though, did you make sure to set up the CelebAHQCrop environment before cropping?

iseunghoon commented 1 year ago

I adjusted the code except two images. Thank you!!

andrewhou1 commented 1 year ago

Hi there, I think we should still check to make sure nothing is wrong though with your conda environment. I tried the two images that you mentioned and they both passed on my side. I set up the environment from scratch using the cropping_dependencies.txt file that I've committed and both images are successfully cropped with 0 difference from my training images. Did you set up the CelebAHQCrop environment that I mentioned in the README instructions and use that to do the cropping?

It's important to make sure the cropping package versions are the same as what I used since different package versions could lead to differently cropped images which would be problematic during training. It's important to use my cropping_dependencies.txt file as a result and to follow the instructions I provided for setting up that environment.

iseunghoon commented 1 year ago

I checked my conda environment. I found that the cuda version of my server is not equal to your requirements. I think maybe it is critical reason. But I can't change my cuda version because the server that I use is shared with our lab. So I can't check the checklist that you guided to me. Sorry about that. Thank you for helping me.

SEUNGHOON LEE

Integrated MS/Ph.D in MVP Lab, Yonsei University.


LAB 02-2123-7843 Mobile 010-5523-9737

Web github.com/iseunghoon

Email @.***

Yonsei University 50 Yonsei-ro, Seodaemun-gu,

Seoul 03722, Republic of Korea

2022년 7월 27일 (수) 오전 12:58, andrewhou1 @.***>님이 작성:

Hi there, I think we should still check to make sure nothing is wrong though with your conda environment. I tried the two images that you mentioned and they both passed on my side. I set up the environment from scratch using the cropping_dependencies.txt file that I've committed and both images are successfully cropped with 0 difference from my training images. Did you set up the CelebAHQCrop environment that I mentioned in the README instructions and use that to do the cropping?

It's important to make sure the cropping package versions are the same as what I used since different package versions could lead to differently cropped images which would be problematic during training. It's important to use my cropping_dependencies.txt file as a result and to follow the instructions I provided for setting up that environment.

— Reply to this email directly, view it on GitHub https://github.com/andrewhou1/GeomConsistentFR/issues/4#issuecomment-1195668674, or unsubscribe https://github.com/notifications/unsubscribe-auth/APTSNBCQE7KVQCPWLEOPDPLVWADJFANCNFSM54SEHQ2A . You are receiving this because you modified the open/close state.Message ID: @.***>