SaraSadeghi
commited on
Commit
•
a585e5e
1
Parent(s):
37f053f
Update README.md
Browse files
README.md
CHANGED
@@ -77,6 +77,14 @@ print(prediction[0])
|
|
77 |
|
78 |
## Evaluation
|
79 |
For the evaluation use the code below:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
80 |
```python
|
81 |
import torch
|
82 |
import torchaudio
|
@@ -113,14 +121,6 @@ def predict(batch):
|
|
113 |
return batch
|
114 |
|
115 |
dataset = load_dataset("csv", data_files={"test":"path/to/your.csv"}, delimiter=",")["test"]
|
116 |
-
```
|
117 |
-
*Input csv files format:*
|
118 |
-
|
119 |
-
| path| reference|
|
120 |
-
|---|---|
|
121 |
-
| path to audio files | corresponding transcription|
|
122 |
-
|
123 |
-
```
|
124 |
dataset = dataset.map(speech_file_to_array_fn)
|
125 |
|
126 |
result = dataset.map(predict, batched=True, batch_size=4)
|
|
|
77 |
|
78 |
## Evaluation
|
79 |
For the evaluation use the code below:
|
80 |
+
```
|
81 |
+
*Input csv files format:*
|
82 |
+
|
83 |
+
| path| reference|
|
84 |
+
|---|---|
|
85 |
+
| path to audio files | corresponding transcription|
|
86 |
+
|
87 |
+
```
|
88 |
```python
|
89 |
import torch
|
90 |
import torchaudio
|
|
|
121 |
return batch
|
122 |
|
123 |
dataset = load_dataset("csv", data_files={"test":"path/to/your.csv"}, delimiter=",")["test"]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
124 |
dataset = dataset.map(speech_file_to_array_fn)
|
125 |
|
126 |
result = dataset.map(predict, batched=True, batch_size=4)
|