Spaces:
Sleeping
Sleeping
Commit
·
5f754d3
1
Parent(s):
fad4683
qwer
Browse files- my_metricv2.py +3 -3
my_metricv2.py
CHANGED
|
@@ -73,10 +73,10 @@ class MyMetricv2(evaluate.Metric):
|
|
| 73 |
# This defines the format of each prediction and reference
|
| 74 |
features=datasets.Features({
|
| 75 |
"predictions": [
|
| 76 |
-
datasets.
|
| 77 |
],
|
| 78 |
"references": [
|
| 79 |
-
datasets.
|
| 80 |
],
|
| 81 |
}),
|
| 82 |
# Homepage of the module for documentation
|
|
@@ -99,7 +99,7 @@ class MyMetricv2(evaluate.Metric):
|
|
| 99 |
# predictions array de formato []
|
| 100 |
|
| 101 |
# accuracy = sum(i == j for i, j in zip(predictions, references)) / len(predictions)
|
| 102 |
-
|
| 103 |
|
| 104 |
return {
|
| 105 |
|
|
|
|
| 73 |
# This defines the format of each prediction and reference
|
| 74 |
features=datasets.Features({
|
| 75 |
"predictions": [
|
| 76 |
+
datasets.Value("float32")
|
| 77 |
],
|
| 78 |
"references": [
|
| 79 |
+
datasets.Value("float32")
|
| 80 |
],
|
| 81 |
}),
|
| 82 |
# Homepage of the module for documentation
|
|
|
|
| 99 |
# predictions array de formato []
|
| 100 |
|
| 101 |
# accuracy = sum(i == j for i, j in zip(predictions, references)) / len(predictions)
|
| 102 |
+
|
| 103 |
|
| 104 |
return {
|
| 105 |
|