Spaces:
Runtime error
Runtime error
Helpful field defaults
Browse files
app.py
CHANGED
|
@@ -48,6 +48,9 @@ def try_parse_yaml(yaml_block):
|
|
| 48 |
|
| 49 |
|
| 50 |
def main():
|
|
|
|
|
|
|
|
|
|
| 51 |
st.markdown("## 1. Load your model's metadata")
|
| 52 |
st.markdown("Enter your model's path below.")
|
| 53 |
model_id = st.text_input("", placeholder="<username>/<model>")
|
|
@@ -172,16 +175,16 @@ def main():
|
|
| 172 |
dataset_name_kwargs = {}
|
| 173 |
if (
|
| 174 |
len(metadata["model-index"][0]["results"]) > 0
|
| 175 |
-
and "dataset" in metadata["model-index"][0]["results"]
|
| 176 |
):
|
| 177 |
-
if "type" in metadata["model-index"][0]["results"]["dataset"]:
|
| 178 |
-
dataset_path_kwargs["value"] = metadata["model-index"][0]["results"][
|
| 179 |
"dataset"
|
| 180 |
]["type"]
|
| 181 |
-
if "name" in metadata["model-index"][0]["results"]["dataset"]:
|
| 182 |
-
dataset_name_kwargs["value"] = metadata["model-index"][0]["results"][
|
| 183 |
"dataset"
|
| 184 |
-
]["
|
| 185 |
|
| 186 |
with st.form(key="eval_form"):
|
| 187 |
dataset_path = st.text_input(
|
|
|
|
| 48 |
|
| 49 |
|
| 50 |
def main():
|
| 51 |
+
st.markdown("# The π€ Speech Bench Metrics Editor")
|
| 52 |
+
st.markdown("This tool will help you report the evaluation metrics for all of your speech recognition models. "
|
| 53 |
+
"Follow the steps and watch your models appear on the [Speech Bench Leaderboard](https://huggingface.co/spaces/huggingface/hf-speech-bench)!")
|
| 54 |
st.markdown("## 1. Load your model's metadata")
|
| 55 |
st.markdown("Enter your model's path below.")
|
| 56 |
model_id = st.text_input("", placeholder="<username>/<model>")
|
|
|
|
| 175 |
dataset_name_kwargs = {}
|
| 176 |
if (
|
| 177 |
len(metadata["model-index"][0]["results"]) > 0
|
| 178 |
+
and "dataset" in metadata["model-index"][0]["results"][0]
|
| 179 |
):
|
| 180 |
+
if "type" in metadata["model-index"][0]["results"][0]["dataset"]:
|
| 181 |
+
dataset_path_kwargs["value"] = metadata["model-index"][0]["results"][0][
|
| 182 |
"dataset"
|
| 183 |
]["type"]
|
| 184 |
+
if "name" in metadata["model-index"][0]["results"][0]["dataset"]:
|
| 185 |
+
dataset_name_kwargs["value"] = metadata["model-index"][0]["results"][0][
|
| 186 |
"dataset"
|
| 187 |
+
]["name"]
|
| 188 |
|
| 189 |
with st.form(key="eval_form"):
|
| 190 |
dataset_path = st.text_input(
|