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

Add probability and perplexity calculation to HFLM #76

Closed
wants to merge 4 commits into from

Conversation

qingyangliu0065
Copy link
Collaborator

Description

This PR implemented the calculate_probability and calculate_perplexity, calculate_perplexity_batch in HuggingFaceLM module. The correctness of two functions has been thoroughly tested using the Detoxified LM notebook, and the corresponding evaluation code in this notebook has been replaced using llments library.

References

@qingyangliu0065 qingyangliu0065 marked this pull request as draft October 10, 2024 23:01
@qingyangliu0065 qingyangliu0065 deleted the cal_prob_HFLM branch October 10, 2024 23:34
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

Successfully merging this pull request may close these issues.

Implementation of Hugging Face LMs
1 participant