Hugging Face
Models
Datasets
Spaces
Community
Docs
Enterprise
Pricing
Log In
Sign Up
Spaces:
d0rj
/
romb-leaderboard
like
0
Sleeping
App
Files
Files
Community
Fetching metadata from the HF Docker repository...
9445c3c
romb-leaderboard
/
src
/
eval
/
metrics.py
d0rj
feat: Initial commit
1719436
about 1 month ago
raw
Copy download link
history
blame
Safe
178 Bytes
import
numpy
as
np
def
grade_to_weight
(
g:
str
) ->
float
:
"""Convert a grade string to a weight value."""
parts =
list
(
map
(
int
, g.split(
'-'
)))
return
np.mean(parts)