fixed duplicate calculation of spearmanr function in metrics wrapper.
{'login': 'benlipkin', 'id': 38060297, 'node_id': 'MDQ6VXNlcjM4MDYwMjk3', 'avatar_url': 'https://avatars.githubusercontent.com/u/38060297?v=4', 'gravatar_id': '', 'url': 'https://api.github.com/users/benlipkin', 'html_url': 'https://github.com/benlipkin', 'followers_url': 'https://api.github.com/users/benlipkin/followers', 'following_url': 'https://api.github.com/users/benlipkin/following{/other_user}', 'gists_url': 'https://api.github.com/users/benlipkin/gists{/gist_id}', 'starred_url': 'https://api.github.com/users/benlipkin/starred{/owner}{/repo}', 'subscriptions_url': 'https://api.github.com/users/benlipkin/subscriptions', 'organizations_url': 'https://api.github.com/users/benlipkin/orgs', 'repos_url': 'https://api.github.com/users/benlipkin/repos', 'events_url': 'https://api.github.com/users/benlipkin/events{/privacy}', 'received_events_url': 'https://api.github.com/users/benlipkin/received_events', 'type': 'User', 'site_admin': False}
[]
[]
['Great, can open a PR in `evaluate` as well to optimize this.\r\n\r\nRelatedly, I wanted to add a new metric, Kendall Tau (https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.kendalltau.html). If I were to open a PR with the wrapper, description, citation, docstrings, readme, etc. would it make more sense to do that in the `datasets` or `evaluate` repo (or both)?\r\n\r\nThanks!'
 'PR opened in`evaluate` library with same minor adjustment: https://github.com/huggingface/evaluate/pull/176 '
 "> If I were to open a PR with the wrapper, description, citation, docstrings, readme, etc. would it make more sense to do that in the datasets or evaluate repo (or both)?\r\n\r\nI think you could just add it to `evaluate`, we're not adding new metrics in this repo anymore"]
{'url': 'https://api.github.com/repos/huggingface/datasets/pulls/4627', 'html_url': 'https://github.com/huggingface/datasets/pull/4627', 'diff_url': 'https://github.com/huggingface/datasets/pull/4627.diff', 'patch_url': 'https://github.com/huggingface/datasets/pull/4627.patch', 'merged_at': datetime.datetime(2022, 7, 7, 12, 41, 9)}
During _compute, the scipy.stats spearmanr function was called twice, redundantly, once for calculating the score and once for calculating the p-value, under the conditional branch where return_pvalue=True. I adjusted the _compute function to execute the spearmanr function once, store the results tuple in a temporary variable, and then pass the indexed contents to the expected keys of the returned dictionary.
{'url': 'https://api.github.com/repos/huggingface/datasets/issues/4627/reactions', 'total_count': 0, '+1': 0, '-1': 0, 'laugh': 0, 'hooray': 0, 'confused': 0, 'heart': 0, 'rocket': 0, 'eyes': 0}