Audio Classification
Transformers
TensorBoard
Safetensors
audio-spectrogram-transformer
Generated from Trainer
Eval Results (legacy)
Instructions to use anand095/ast-finetuned-custom with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use anand095/ast-finetuned-custom with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("audio-classification", model="anand095/ast-finetuned-custom")# pip install -U transformers accelerate # Load model directly from transformers import AutoFeatureExtractor, AutoModelForAudioClassification extractor = AutoFeatureExtractor.from_pretrained("anand095/ast-finetuned-custom") model = AutoModelForAudioClassification.from_pretrained("anand095/ast-finetuned-custom", device_map="auto") - Notebooks
- Google Colab
- Kaggle
End of training
Browse files- README.md +81 -0
- config.json +48 -0
- model.safetensors +3 -0
- runs/Nov02_14-27-34_a624dc91c79a/events.out.tfevents.1762093655.a624dc91c79a.19.0 +3 -0
- training_args.bin +3 -0
README.md
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: transformers
|
| 3 |
+
license: bsd-3-clause
|
| 4 |
+
base_model: MIT/ast-finetuned-audioset-10-10-0.4593
|
| 5 |
+
tags:
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
datasets:
|
| 8 |
+
- marsyas/gtzan
|
| 9 |
+
metrics:
|
| 10 |
+
- accuracy
|
| 11 |
+
model-index:
|
| 12 |
+
- name: ast-finetuned-gtzan
|
| 13 |
+
results:
|
| 14 |
+
- task:
|
| 15 |
+
name: Audio Classification
|
| 16 |
+
type: audio-classification
|
| 17 |
+
dataset:
|
| 18 |
+
name: GTZAN
|
| 19 |
+
type: marsyas/gtzan
|
| 20 |
+
config: default
|
| 21 |
+
split: train
|
| 22 |
+
args: default
|
| 23 |
+
metrics:
|
| 24 |
+
- name: Accuracy
|
| 25 |
+
type: accuracy
|
| 26 |
+
value: 0.87
|
| 27 |
+
---
|
| 28 |
+
|
| 29 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
| 30 |
+
should probably proofread and complete it, then remove this comment. -->
|
| 31 |
+
|
| 32 |
+
# ast-finetuned-gtzan
|
| 33 |
+
|
| 34 |
+
This model is a fine-tuned version of [MIT/ast-finetuned-audioset-10-10-0.4593](https://huggingface.co/MIT/ast-finetuned-audioset-10-10-0.4593) on the GTZAN dataset.
|
| 35 |
+
It achieves the following results on the evaluation set:
|
| 36 |
+
- Loss: 0.3930
|
| 37 |
+
- Accuracy: 0.87
|
| 38 |
+
|
| 39 |
+
## Model description
|
| 40 |
+
|
| 41 |
+
More information needed
|
| 42 |
+
|
| 43 |
+
## Intended uses & limitations
|
| 44 |
+
|
| 45 |
+
More information needed
|
| 46 |
+
|
| 47 |
+
## Training and evaluation data
|
| 48 |
+
|
| 49 |
+
More information needed
|
| 50 |
+
|
| 51 |
+
## Training procedure
|
| 52 |
+
|
| 53 |
+
### Training hyperparameters
|
| 54 |
+
|
| 55 |
+
The following hyperparameters were used during training:
|
| 56 |
+
- learning_rate: 2e-05
|
| 57 |
+
- train_batch_size: 16
|
| 58 |
+
- eval_batch_size: 8
|
| 59 |
+
- seed: 42
|
| 60 |
+
- optimizer: Use OptimizerNames.ADAMW_TORCH with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
|
| 61 |
+
- lr_scheduler_type: linear
|
| 62 |
+
- lr_scheduler_warmup_ratio: 0.15
|
| 63 |
+
- num_epochs: 5
|
| 64 |
+
|
| 65 |
+
### Training results
|
| 66 |
+
|
| 67 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|
| 68 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------:|
|
| 69 |
+
| 1.4964 | 1.0 | 57 | 0.6520 | 0.79 |
|
| 70 |
+
| 0.4667 | 2.0 | 114 | 0.4928 | 0.82 |
|
| 71 |
+
| 0.217 | 3.0 | 171 | 0.4175 | 0.88 |
|
| 72 |
+
| 0.0613 | 4.0 | 228 | 0.3876 | 0.88 |
|
| 73 |
+
| 0.0441 | 5.0 | 285 | 0.3930 | 0.87 |
|
| 74 |
+
|
| 75 |
+
|
| 76 |
+
### Framework versions
|
| 77 |
+
|
| 78 |
+
- Transformers 4.53.3
|
| 79 |
+
- Pytorch 2.6.0+cu124
|
| 80 |
+
- Datasets 3.6.0
|
| 81 |
+
- Tokenizers 0.21.2
|
config.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"ASTForAudioClassification"
|
| 4 |
+
],
|
| 5 |
+
"attention_probs_dropout_prob": 0.0,
|
| 6 |
+
"frequency_stride": 10,
|
| 7 |
+
"hidden_act": "gelu",
|
| 8 |
+
"hidden_dropout_prob": 0.0,
|
| 9 |
+
"hidden_size": 768,
|
| 10 |
+
"id2label": {
|
| 11 |
+
"0": "blues",
|
| 12 |
+
"1": "classical",
|
| 13 |
+
"2": "country",
|
| 14 |
+
"3": "disco",
|
| 15 |
+
"4": "hiphop",
|
| 16 |
+
"5": "jazz",
|
| 17 |
+
"6": "metal",
|
| 18 |
+
"7": "pop",
|
| 19 |
+
"8": "reggae",
|
| 20 |
+
"9": "rock"
|
| 21 |
+
},
|
| 22 |
+
"initializer_range": 0.02,
|
| 23 |
+
"intermediate_size": 3072,
|
| 24 |
+
"label2id": {
|
| 25 |
+
"blues": 0,
|
| 26 |
+
"classical": 1,
|
| 27 |
+
"country": 2,
|
| 28 |
+
"disco": 3,
|
| 29 |
+
"hiphop": 4,
|
| 30 |
+
"jazz": 5,
|
| 31 |
+
"metal": 6,
|
| 32 |
+
"pop": 7,
|
| 33 |
+
"reggae": 8,
|
| 34 |
+
"rock": 9
|
| 35 |
+
},
|
| 36 |
+
"layer_norm_eps": 1e-12,
|
| 37 |
+
"max_length": 1024,
|
| 38 |
+
"model_type": "audio-spectrogram-transformer",
|
| 39 |
+
"num_attention_heads": 12,
|
| 40 |
+
"num_hidden_layers": 12,
|
| 41 |
+
"num_mel_bins": 128,
|
| 42 |
+
"patch_size": 16,
|
| 43 |
+
"problem_type": "single_label_classification",
|
| 44 |
+
"qkv_bias": true,
|
| 45 |
+
"time_stride": 10,
|
| 46 |
+
"torch_dtype": "float32",
|
| 47 |
+
"transformers_version": "4.53.3"
|
| 48 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:46641c69ab07eb7904f9f9ee94db3cc57b42c62b8ae97a29763c51b21f1ba3d0
|
| 3 |
+
size 344814656
|
runs/Nov02_14-27-34_a624dc91c79a/events.out.tfevents.1762093655.a624dc91c79a.19.0
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:efdf006974a31c6553f6a889b3f2009944252ded24344803d2500a8dccb6de31
|
| 3 |
+
size 8317
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:228af79f6ec97e5e73dc33917820a9e8db878be21ff3abfd820199f03dcd85ff
|
| 3 |
+
size 5368
|