Spaces:
Running
Running
Simplify returned labels
Browse files
app.py
CHANGED
|
@@ -87,12 +87,12 @@ def process_func(x: np.ndarray, sampling_rate: int) -> dict:
|
|
| 87 |
y = y.detach().cpu().numpy()
|
| 88 |
|
| 89 |
# convert to dict
|
| 90 |
-
y =
|
| 91 |
-
|
| 92 |
-
|
| 93 |
-
|
| 94 |
-
|
| 95 |
-
|
| 96 |
|
| 97 |
return y
|
| 98 |
|
|
|
|
| 87 |
y = y.detach().cpu().numpy()
|
| 88 |
|
| 89 |
# convert to dict
|
| 90 |
+
y = {
|
| 91 |
+
"age": 100 * y[0][0],
|
| 92 |
+
"female": y[0][1],
|
| 93 |
+
"male": y[0][2],
|
| 94 |
+
"child": y[0][3],
|
| 95 |
+
}
|
| 96 |
|
| 97 |
return y
|
| 98 |
|