Spaces:
Sleeping
Sleeping
Renaming repo to `phone_errors`
Browse files- README.md +4 -4
- app.py +1 -1
- phone_distance.py +4 -4
README.md
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
tags:
|
4 |
- evaluate
|
5 |
- metric
|
6 |
description: >-
|
7 |
-
|
8 |
between strings in the International Phonetic Alphabet (IPA) in a linguistically motivated way.
|
9 |
This is useful when evaluating speech recognition or orthographic to IPA conversion tasks.
|
10 |
sdk: gradio
|
@@ -16,14 +16,14 @@ pinned: false
|
|
16 |
# Metric Card for Phone Distance
|
17 |
|
18 |
## Metric Description
|
19 |
-
|
20 |
This is useful when evaluating speech recognition or orthographic to IPA conversion tasks. These are Levenshtein distances for comparing strings where the smallest unit of measurement is based on phones or articulatory phonological features, rather than Unicode characters.
|
21 |
|
22 |
## How to Use
|
23 |
|
24 |
```python
|
25 |
import evaluate
|
26 |
-
phone_distance = evaluate.load("ginic/
|
27 |
phone_distance.compute(predictions=["bob", "ði"], references=["pop", "ðə"])
|
28 |
```
|
29 |
|
|
|
1 |
---
|
2 |
+
title: phone_errors
|
3 |
tags:
|
4 |
- evaluate
|
5 |
- metric
|
6 |
description: >-
|
7 |
+
Error rates in terms of distance between articulatory phonological features can help understand differences
|
8 |
between strings in the International Phonetic Alphabet (IPA) in a linguistically motivated way.
|
9 |
This is useful when evaluating speech recognition or orthographic to IPA conversion tasks.
|
10 |
sdk: gradio
|
|
|
16 |
# Metric Card for Phone Distance
|
17 |
|
18 |
## Metric Description
|
19 |
+
Error rates in terms of distance between articulatory phonological features can help understand differences between strings in the International Phonetic Alphabet (IPA) in a linguistically motivated way.
|
20 |
This is useful when evaluating speech recognition or orthographic to IPA conversion tasks. These are Levenshtein distances for comparing strings where the smallest unit of measurement is based on phones or articulatory phonological features, rather than Unicode characters.
|
21 |
|
22 |
## How to Use
|
23 |
|
24 |
```python
|
25 |
import evaluate
|
26 |
+
phone_distance = evaluate.load("ginic/phone_errors")
|
27 |
phone_distance.compute(predictions=["bob", "ði"], references=["pop", "ðə"])
|
28 |
```
|
29 |
|
app.py
CHANGED
@@ -2,5 +2,5 @@ import evaluate
|
|
2 |
from evaluate.utils import launch_gradio_widget
|
3 |
|
4 |
|
5 |
-
module = evaluate.load("ginic/
|
6 |
launch_gradio_widget(module)
|
|
|
2 |
from evaluate.utils import launch_gradio_widget
|
3 |
|
4 |
|
5 |
+
module = evaluate.load("ginic/phone_errors")
|
6 |
launch_gradio_widget(module)
|
phone_distance.py
CHANGED
@@ -38,9 +38,9 @@ _CITATION = """\
|
|
38 |
"""
|
39 |
|
40 |
_DESCRIPTION = """
|
41 |
-
|
42 |
between strings in the International Phonetic Alphabet (IPA) in a linguistically motivated way.
|
43 |
-
This is useful when evaluating speech recognition or orthographic to IPA conversion tasks.
|
44 |
"""
|
45 |
|
46 |
|
@@ -71,12 +71,12 @@ Returns:
|
|
71 |
|
72 |
Examples:
|
73 |
Compare articulatory differences in voicing in "bob" vs. "pop" and different pronunciations of "the":
|
74 |
-
>>> phone_distance = evaluate.load("ginic/
|
75 |
>>> phone_distance.compute(predictions=["bob", "ði"], references=["pop", "ðə"])
|
76 |
{'phone_error_rates': [0.6666666666666666, 0.5], 'mean_phone_error_rate': 0.5833333333333333, 'phone_feature_error_rates': [0.08333333333333333, 0.125], 'mean_phone_feature_error_rates': 0.10416666666666666, 'feature_error_rates': [0.027777777777777776, 0.0625], 'mean_feature_error_rates': 0.04513888888888889}
|
77 |
|
78 |
Normalize PFER by the length of string with largest number of phones:
|
79 |
-
>>> phone_distance = evaluate.load("ginic/
|
80 |
>>> phone_distance.compute(predictions=["bob", "ði"], references=["pop", "ðə"], is_normalize_pfer=True)
|
81 |
|
82 |
"""
|
|
|
38 |
"""
|
39 |
|
40 |
_DESCRIPTION = """
|
41 |
+
Error rates in terms of distance between articulatory phonological features can help understand differences
|
42 |
between strings in the International Phonetic Alphabet (IPA) in a linguistically motivated way.
|
43 |
+
This is useful when evaluating speech recognition or orthographic to IPA conversion tasks.
|
44 |
"""
|
45 |
|
46 |
|
|
|
71 |
|
72 |
Examples:
|
73 |
Compare articulatory differences in voicing in "bob" vs. "pop" and different pronunciations of "the":
|
74 |
+
>>> phone_distance = evaluate.load("ginic/phone_errors")
|
75 |
>>> phone_distance.compute(predictions=["bob", "ði"], references=["pop", "ðə"])
|
76 |
{'phone_error_rates': [0.6666666666666666, 0.5], 'mean_phone_error_rate': 0.5833333333333333, 'phone_feature_error_rates': [0.08333333333333333, 0.125], 'mean_phone_feature_error_rates': 0.10416666666666666, 'feature_error_rates': [0.027777777777777776, 0.0625], 'mean_feature_error_rates': 0.04513888888888889}
|
77 |
|
78 |
Normalize PFER by the length of string with largest number of phones:
|
79 |
+
>>> phone_distance = evaluate.load("ginic/phone_errors")
|
80 |
>>> phone_distance.compute(predictions=["bob", "ði"], references=["pop", "ðə"], is_normalize_pfer=True)
|
81 |
|
82 |
"""
|