Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Closed
ygtxr1997 opened this issue Sep 5, 2022 · 2 comments
Closed

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

ygtxr1997 opened this issue Sep 5, 2022 · 2 comments

Comments

@ygtxr1997
Copy link

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
Copy link
Owner

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.

elif self.mode == 'Mask' or self.mode == 'Occ':
if random.choice(range(self.ratio)) == 0:
return img, 0
else:
img_occ, mask_label, mask = self.occlude_img(img)
return img_occ, mask_label

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
Copy link
Author

Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants