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 effect of labels[0, :start_token] = -100 #20

Closed
lygjwy opened this issue Jun 18, 2024 · 1 comment
Closed

Question about the effect of labels[0, :start_token] = -100 #20

lygjwy opened this issue Jun 18, 2024 · 1 comment

Comments

@lygjwy
Copy link

lygjwy commented Jun 18, 2024

Hi, I don't understand the function of code 'labels[0, :start_token] = -100' in Line 68 from cherry_seletion/data_analysis.py file.

@MingLiiii
Copy link
Collaborator

Sorry for the late reply! The use of = -100 is to make LLMs ignore the calculation of loss on those positions.

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