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

Why isn't the loss calculated only with b_i=0 values of the Hints. #36

Closed
javiersgjavi opened this issue Mar 13, 2023 · 2 comments
Closed

Comments

@javiersgjavi
Copy link

Hello,

First of all, congratulations four your fantastic paper. I have been reading it and working with your repository; however, I have a doubt and would appreciate it if you could answer it.

I know a couple of changes exist between the implementation described in the original paper and the one in this repository. Also, I have checked some closed issues as #2, where the new implementation of the Hint matrix is described.

In your original article, when you are talking about how the algorithm works in section 5, it can be seen that the discriminator loss is only calculated with the b_i = 0 of each sample, that is, the positions where there isn't a hint. Also, in the same paragraph, it can be seen that if you train with all the values, the discriminator will overfit to the hint matrix.

Despite this, when I check your code, I have the impression that you calculate D_loss and G_loss with all the values of the hint matrix (b_i=0 and b_i=1) in the lines 136-139.

I want to ask you if this change is due to the difference in the definition of the Hint matrix and why doesn't this new way of calculating the loss ends in the discriminator overfitting to the hint matrix.

Thank you very much for your attention!

@javiersgjavi javiersgjavi changed the title Why isn't the loss calculates only with b_i=0 values of the Hints. Why isn't the loss calculated only with b_i=0 values of the Hints. Mar 13, 2023
@jsyoon0823
Copy link
Owner

Thanks for your interest in our work.
First, yes. you are correct. We calculate the loss for the components with hint and without hint.
There are pros and cons to do this.

  • Cons: As you said, it may overfit to the hint.
  • Pros: It helps discriminator to utilize the hint more explicitly.

For the cons, we think that only with hint, the discriminator cannot solve the task perfectly; thus, we think it may not only just overfit on the hint.

Therefore, we focus more on pros and use this as the official implementation.

Thanks!

@javiersgjavi
Copy link
Author

Thank you very much for your answer! It has been helpful.

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