Skip to content

Commit

Permalink
Merge pull request #142 from MKhalusova/next-127
Browse files Browse the repository at this point in the history
Fixed issue with missing .copy un U4
  • Loading branch information
MKhalusova authored Sep 26, 2023
2 parents 44c0ab5 + d25911e commit 0b0b7d4
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions chapters/en/chapter4/classification_models.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ checkpoint fine-tuned on the Speech Commands dataset, under the namespace [`"MIT
classifier = pipeline(
"audio-classification", model="MIT/ast-finetuned-speech-commands-v2"
)
classifier(sample["audio"])
classifier(sample["audio"].copy())
```
**Output:**
```
Expand All @@ -147,7 +147,6 @@ and verify this is correct:
```
from IPython.display import Audio
classifier(sample["audio"].copy())
Audio(sample["audio"]["array"], rate=sample["audio"]["sampling_rate"])
```

Expand Down
2 changes: 1 addition & 1 deletion chapters/fr/chapter4/classification_models.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ Nous allons charger un *checkpoint* d’un [*transformer* d’audio sous la form
classifier = pipeline(
"audio-classification", model="MIT/ast-finetuned-speech-commands-v2"
)
classifier(sample["audio"])
classifier(sample["audio"].copy())
```

**Sortie :**
Expand Down
3 changes: 1 addition & 2 deletions chapters/ru/chapter4/classification_models.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ sample = next(iter(speech_commands))
classifier = pipeline(
"audio-classification", model="MIT/ast-finetuned-speech-commands-v2"
)
classifier(sample["audio"])
classifier(sample["audio"].copy())
```
**Output:**
```
Expand All @@ -144,7 +144,6 @@ classifier(sample["audio"])
```
from IPython.display import Audio
classifier(sample["audio"].copy())
Audio(sample["audio"]["array"], rate=sample["audio"]["sampling_rate"])
```

Expand Down

0 comments on commit 0b0b7d4

Please sign in to comment.