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

Potential bug in weighting trigger candidate losses #4

Open
davides opened this issue Dec 8, 2022 · 0 comments
Open

Potential bug in weighting trigger candidate losses #4

davides opened this issue Dec 8, 2022 · 0 comments

Comments

@davides
Copy link

davides commented Dec 8, 2022

First, thanks for publishing your implementation of this technique. It's been very helpful!

While stepping through the code, I think I may have found a small issue. The goal of this code seems to be: re-weight the loss contributed by each batch by the fraction of unmasked tokens it contains.

If that's the case, shouldn't curr_num_elements count all elements != constants.PAD_TOKEN_ID (-100), instead of -1?

Thanks!

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

1 participant