haibo-qiu / FROM

[TPAMI 2021] End2End Occluded Face Recognition by Masking Corrupted Features
https://arxiv.org/abs/2108.09468
43 stars 8 forks source link

How many images are there in one training epoch? #4

Closed ygtxr1997 closed 2 years ago

ygtxr1997 commented 2 years ago

Your paper says that 'Mix-WebFace is the mixup of Occ-WebFace and WebFace with the ratio 2:1'. How many images in the Occ-WebFace? How many images in one training epoch after mixing up Occ-WebFace and WebFace?

haibo-qiu commented 2 years ago

Hi @ygtxr1997

Our statement 'Mix-WebFace is the mixup of Occ-WebFace and WebFace with the ratio 2:1' might be a little bit confusing. The practical situation is that when iterating images in WebFace, each image has a 2/3 probability of being masked and a 1/3 probability of keeping clean. You can refer to the below code where the self.ratio is 3.

https://github.com/haibo-qiu/FROM/blob/6b825c690c74672ec4e913ee87fa6a67f0edbb82/lib/datasets/dataset.py#L175-L180

Thus the total images in one epoch are the same as WebFace images, nearly 500k.

The Occ-WebFace means masking each image in WebFace with the random scale from 1:0.5:5 (1, 1.5, 2.0....5.0) when training, which also leads to the same account of images (500k).

ygtxr1997 commented 2 years ago

Thank you very much!