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

Question About the ClipCocoDataset in train.py #34

Closed
ycchanau opened this issue Mar 26, 2022 · 1 comment
Closed

Question About the ClipCocoDataset in train.py #34

ycchanau opened this issue Mar 26, 2022 · 1 comment

Comments

@ycchanau
Copy link

image

I have a question about the above code. I observe that in the pad_tokens function, it will save the padded token. However, if we call the pad_tokens function with the same token again, the padded token saved where the padded part is set to 0, will be used to generate the mask with ge(0), as a result, the mask will always be one for all positions. Do I miss something?

@bofang98
Copy link

I found the same problem... The mask is correct for the 1st epoch only. And it will be all 1's for all positions after the 1st epoch.

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