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

fixed duplicate calculation of spearmanr function in metrics wrapper. #176

Merged

Conversation

benlipkin
Copy link
Contributor

In spearmanr metric _evaluate function, wrapped scipy.stats function is called twice, once for score and once for p-value, resulting in redundant duplicate calculation. Adjusted here to only run calculation once. Already opened PR in huggingface/datasets (huggingface/datasets#4627) and am matching here.

Copy link
Member

@lvwerra lvwerra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @benlipkin, thanks for this, this is indeed more efficient!

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Jul 6, 2022

The documentation is not available anymore as the PR was closed or merged.

@lvwerra lvwerra merged commit 4f4e17d into huggingface:main Jul 7, 2022
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.

None yet

3 participants