Instructions to use mispeech/ced-small with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use mispeech/ced-small with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("audio-classification", model="mispeech/ced-small", trust_remote_code=True)# Load model directly from transformers import AutoModelForAudioClassification model = AutoModelForAudioClassification.from_pretrained("mispeech/ced-small", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Commit ·
7ee0cd5
1
Parent(s): c0b222d
Update README.md
Browse files
README.md
CHANGED
|
@@ -36,9 +36,9 @@ pip install -r requirements.txt
|
|
| 36 |
>>> from ced_model.feature_extraction_ced import CedFeatureExtractor
|
| 37 |
>>> from ced_model.modeling_ced import CedForAudioClassification
|
| 38 |
|
| 39 |
-
>>>
|
| 40 |
-
>>> feature_extractor = CedFeatureExtractor.from_pretrained(
|
| 41 |
-
>>> model = CedForAudioClassification.from_pretrained(
|
| 42 |
|
| 43 |
>>> import torchaudio
|
| 44 |
>>> audio, sampling_rate = torchaudio.load("resources/JeD5V5aaaoI_931_932.wav")
|
|
|
|
| 36 |
>>> from ced_model.feature_extraction_ced import CedFeatureExtractor
|
| 37 |
>>> from ced_model.modeling_ced import CedForAudioClassification
|
| 38 |
|
| 39 |
+
>>> model_id = "mispeech/ced-small"
|
| 40 |
+
>>> feature_extractor = CedFeatureExtractor.from_pretrained(model_id)
|
| 41 |
+
>>> model = CedForAudioClassification.from_pretrained(model_id)
|
| 42 |
|
| 43 |
>>> import torchaudio
|
| 44 |
>>> audio, sampling_rate = torchaudio.load("resources/JeD5V5aaaoI_931_932.wav")
|