Fix double backslashs
Browse files
README.md
CHANGED
@@ -39,7 +39,7 @@ model = Wav2Vec2ForCTC.from_pretrained("Marxav/wav2vec2-large-xlsr-53-breton")
|
|
39 |
|
40 |
resampler = torchaudio.transforms.Resample(48_000, 16_000)
|
41 |
|
42 |
-
chars_to_ignore_regex = '[
|
43 |
|
44 |
# Preprocessing the datasets.
|
45 |
# We need to read the audio files as arrays
|
@@ -67,7 +67,7 @@ print("Reference:", test_dataset["sentence"][:nb_samples])
|
|
67 |
```
|
68 |
The above code leads to the following prediction for the first two samples:
|
69 |
* Prediction: ["nel ler ket dont abenn eus netra la vez ser mirc'hid evel sij", 'an eil hag egile']
|
70 |
-
* Reference: [
|
71 |
|
72 |
The model can be evaluated as follows on the {language} test data of Common Voice.
|
73 |
```python
|
@@ -85,7 +85,7 @@ processor = Wav2Vec2Processor.from_pretrained('Marxav/wav2vec2-large-xlsr-53-bre
|
|
85 |
model = Wav2Vec2ForCTC.from_pretrained('Marxav/wav2vec2-large-xlsr-53-breton2')
|
86 |
model.to("cuda")
|
87 |
|
88 |
-
chars_to_ignore_regex = '[
|
89 |
|
90 |
resampler = torchaudio.transforms.Resample(48_000, 16_000)
|
91 |
|
|
|
39 |
|
40 |
resampler = torchaudio.transforms.Resample(48_000, 16_000)
|
41 |
|
42 |
+
chars_to_ignore_regex = '[\\,\,\?\.\!\;\:\"\“\%\”\�\(\)\/\«\»\½\…]'
|
43 |
|
44 |
# Preprocessing the datasets.
|
45 |
# We need to read the audio files as arrays
|
|
|
67 |
```
|
68 |
The above code leads to the following prediction for the first two samples:
|
69 |
* Prediction: ["nel ler ket dont abenn eus netra la vez ser mirc'hid evel sij", 'an eil hag egile']
|
70 |
+
* Reference: ["N'haller ket dont a-benn eus netra pa vezer nec'het evel-se ", 'An eil hag egile ']
|
71 |
|
72 |
The model can be evaluated as follows on the {language} test data of Common Voice.
|
73 |
```python
|
|
|
85 |
model = Wav2Vec2ForCTC.from_pretrained('Marxav/wav2vec2-large-xlsr-53-breton2')
|
86 |
model.to("cuda")
|
87 |
|
88 |
+
chars_to_ignore_regex = '[\\,\,\?\.\!\;\:\"\“\%\”\�\(\)\/\«\»\½\…]'
|
89 |
|
90 |
resampler = torchaudio.transforms.Resample(48_000, 16_000)
|
91 |
|