Audio Classification
Transformers
English
audio
audio-captioning
audio-tagging
audioset
whisper
speech-captioning
music-captioning
sound-effect-captioning
laion
ast
audio-spectrogram-transformer
Instructions to use laion/whisper-captioning-ensemble with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use laion/whisper-captioning-ensemble with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("audio-classification", model="laion/whisper-captioning-ensemble")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("laion/whisper-captioning-ensemble", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update pipeline.py
Browse files- pipeline.py +2 -1
pipeline.py
CHANGED
|
@@ -268,7 +268,8 @@ def _run_ast_batch(
|
|
| 268 |
for idx, conf in zip(i_row, v_row)
|
| 269 |
]
|
| 270 |
topk_per_file.append(labels_with_conf)
|
| 271 |
-
|
|
|
|
| 272 |
return topk_per_file, routes
|
| 273 |
|
| 274 |
|
|
|
|
| 268 |
for idx, conf in zip(i_row, v_row)
|
| 269 |
]
|
| 270 |
topk_per_file.append(labels_with_conf)
|
| 271 |
+
top_label, top_conf = labels_with_conf[0]
|
| 272 |
+
routes.append(route_label(top_label, top_conf))
|
| 273 |
return topk_per_file, routes
|
| 274 |
|
| 275 |
|