zarakun/wav2vec
Browse files
README.md
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: transformers
|
| 3 |
+
license: apache-2.0
|
| 4 |
+
base_model: facebook/wav2vec2-base
|
| 5 |
+
tags:
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
datasets:
|
| 8 |
+
- speech_commands
|
| 9 |
+
metrics:
|
| 10 |
+
- accuracy
|
| 11 |
+
- f1
|
| 12 |
+
model-index:
|
| 13 |
+
- name: wav2vec
|
| 14 |
+
results:
|
| 15 |
+
- task:
|
| 16 |
+
name: Audio Classification
|
| 17 |
+
type: audio-classification
|
| 18 |
+
dataset:
|
| 19 |
+
name: speech_commands
|
| 20 |
+
type: speech_commands
|
| 21 |
+
config: v0.01
|
| 22 |
+
split: test
|
| 23 |
+
args: v0.01
|
| 24 |
+
metrics:
|
| 25 |
+
- name: Accuracy
|
| 26 |
+
type: accuracy
|
| 27 |
+
value: 0.8909444985394352
|
| 28 |
+
- name: F1
|
| 29 |
+
type: f1
|
| 30 |
+
value: 0.8408887171290298
|
| 31 |
+
---
|
| 32 |
+
|
| 33 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
| 34 |
+
should probably proofread and complete it, then remove this comment. -->
|
| 35 |
+
|
| 36 |
+
# wav2vec
|
| 37 |
+
|
| 38 |
+
This model is a fine-tuned version of [facebook/wav2vec2-base](https://huggingface.co/facebook/wav2vec2-base) on the speech_commands dataset.
|
| 39 |
+
It achieves the following results on the evaluation set:
|
| 40 |
+
- Loss: 0.8904
|
| 41 |
+
- Accuracy: 0.8909
|
| 42 |
+
- F1: 0.8409
|
| 43 |
+
|
| 44 |
+
## Model description
|
| 45 |
+
|
| 46 |
+
More information needed
|
| 47 |
+
|
| 48 |
+
## Intended uses & limitations
|
| 49 |
+
|
| 50 |
+
More information needed
|
| 51 |
+
|
| 52 |
+
## Training and evaluation data
|
| 53 |
+
|
| 54 |
+
More information needed
|
| 55 |
+
|
| 56 |
+
## Training procedure
|
| 57 |
+
|
| 58 |
+
### Training hyperparameters
|
| 59 |
+
|
| 60 |
+
The following hyperparameters were used during training:
|
| 61 |
+
- learning_rate: 3e-05
|
| 62 |
+
- train_batch_size: 240
|
| 63 |
+
- eval_batch_size: 240
|
| 64 |
+
- seed: 42
|
| 65 |
+
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 66 |
+
- lr_scheduler_type: linear
|
| 67 |
+
- num_epochs: 3
|
| 68 |
+
|
| 69 |
+
### Training results
|
| 70 |
+
|
| 71 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 |
|
| 72 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------:|:------:|
|
| 73 |
+
| 1.4272 | 1.0 | 213 | 1.3926 | 0.8845 | 0.8359 |
|
| 74 |
+
| 0.9354 | 2.0 | 426 | 0.9938 | 0.8877 | 0.8598 |
|
| 75 |
+
| 0.7761 | 3.0 | 639 | 0.8904 | 0.8909 | 0.8409 |
|
| 76 |
+
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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_name_or_path": "facebook/wav2vec2-base",
|
| 3 |
+
"activation_dropout": 0.0,
|
| 4 |
+
"adapter_attn_dim": null,
|
| 5 |
+
"adapter_kernel_size": 3,
|
| 6 |
+
"adapter_stride": 2,
|
| 7 |
+
"add_adapter": false,
|
| 8 |
+
"apply_spec_augment": true,
|
| 9 |
+
"architectures": [
|
| 10 |
+
"Wav2Vec2ForSequenceClassification"
|
| 11 |
+
],
|
| 12 |
+
"attention_dropout": 0.1,
|
| 13 |
+
"bos_token_id": 1,
|
| 14 |
+
"classifier_proj_size": 256,
|
| 15 |
+
"codevector_dim": 256,
|
| 16 |
+
"contrastive_logits_temperature": 0.1,
|
| 17 |
+
"conv_bias": false,
|
| 18 |
+
"conv_dim": [
|
| 19 |
+
512,
|
| 20 |
+
512,
|
| 21 |
+
512,
|
| 22 |
+
512,
|
| 23 |
+
512,
|
| 24 |
+
512,
|
| 25 |
+
512
|
| 26 |
+
],
|
| 27 |
+
"conv_kernel": [
|
| 28 |
+
10,
|
| 29 |
+
3,
|
| 30 |
+
3,
|
| 31 |
+
3,
|
| 32 |
+
3,
|
| 33 |
+
2,
|
| 34 |
+
2
|
| 35 |
+
],
|
| 36 |
+
"conv_stride": [
|
| 37 |
+
5,
|
| 38 |
+
2,
|
| 39 |
+
2,
|
| 40 |
+
2,
|
| 41 |
+
2,
|
| 42 |
+
2,
|
| 43 |
+
2
|
| 44 |
+
],
|
| 45 |
+
"ctc_loss_reduction": "sum",
|
| 46 |
+
"ctc_zero_infinity": false,
|
| 47 |
+
"diversity_loss_weight": 0.1,
|
| 48 |
+
"do_stable_layer_norm": false,
|
| 49 |
+
"eos_token_id": 2,
|
| 50 |
+
"feat_extract_activation": "gelu",
|
| 51 |
+
"feat_extract_norm": "group",
|
| 52 |
+
"feat_proj_dropout": 0.1,
|
| 53 |
+
"feat_quantizer_dropout": 0.0,
|
| 54 |
+
"final_dropout": 0.0,
|
| 55 |
+
"freeze_feat_extract_train": true,
|
| 56 |
+
"hidden_act": "gelu",
|
| 57 |
+
"hidden_dropout": 0.1,
|
| 58 |
+
"hidden_size": 768,
|
| 59 |
+
"id2label": {
|
| 60 |
+
"0": "LABEL_0",
|
| 61 |
+
"1": "LABEL_1",
|
| 62 |
+
"2": "LABEL_2",
|
| 63 |
+
"3": "LABEL_3",
|
| 64 |
+
"4": "LABEL_4",
|
| 65 |
+
"5": "LABEL_5",
|
| 66 |
+
"6": "LABEL_6",
|
| 67 |
+
"7": "LABEL_7",
|
| 68 |
+
"8": "LABEL_8",
|
| 69 |
+
"9": "LABEL_9",
|
| 70 |
+
"10": "LABEL_10",
|
| 71 |
+
"11": "LABEL_11",
|
| 72 |
+
"12": "LABEL_12",
|
| 73 |
+
"13": "LABEL_13",
|
| 74 |
+
"14": "LABEL_14",
|
| 75 |
+
"15": "LABEL_15",
|
| 76 |
+
"16": "LABEL_16",
|
| 77 |
+
"17": "LABEL_17",
|
| 78 |
+
"18": "LABEL_18",
|
| 79 |
+
"19": "LABEL_19",
|
| 80 |
+
"20": "LABEL_20",
|
| 81 |
+
"21": "LABEL_21",
|
| 82 |
+
"22": "LABEL_22",
|
| 83 |
+
"23": "LABEL_23",
|
| 84 |
+
"24": "LABEL_24",
|
| 85 |
+
"25": "LABEL_25",
|
| 86 |
+
"26": "LABEL_26",
|
| 87 |
+
"27": "LABEL_27",
|
| 88 |
+
"28": "LABEL_28",
|
| 89 |
+
"29": "LABEL_29",
|
| 90 |
+
"30": "LABEL_30"
|
| 91 |
+
},
|
| 92 |
+
"initializer_range": 0.02,
|
| 93 |
+
"intermediate_size": 3072,
|
| 94 |
+
"label2id": {
|
| 95 |
+
"LABEL_0": 0,
|
| 96 |
+
"LABEL_1": 1,
|
| 97 |
+
"LABEL_10": 10,
|
| 98 |
+
"LABEL_11": 11,
|
| 99 |
+
"LABEL_12": 12,
|
| 100 |
+
"LABEL_13": 13,
|
| 101 |
+
"LABEL_14": 14,
|
| 102 |
+
"LABEL_15": 15,
|
| 103 |
+
"LABEL_16": 16,
|
| 104 |
+
"LABEL_17": 17,
|
| 105 |
+
"LABEL_18": 18,
|
| 106 |
+
"LABEL_19": 19,
|
| 107 |
+
"LABEL_2": 2,
|
| 108 |
+
"LABEL_20": 20,
|
| 109 |
+
"LABEL_21": 21,
|
| 110 |
+
"LABEL_22": 22,
|
| 111 |
+
"LABEL_23": 23,
|
| 112 |
+
"LABEL_24": 24,
|
| 113 |
+
"LABEL_25": 25,
|
| 114 |
+
"LABEL_26": 26,
|
| 115 |
+
"LABEL_27": 27,
|
| 116 |
+
"LABEL_28": 28,
|
| 117 |
+
"LABEL_29": 29,
|
| 118 |
+
"LABEL_3": 3,
|
| 119 |
+
"LABEL_30": 30,
|
| 120 |
+
"LABEL_4": 4,
|
| 121 |
+
"LABEL_5": 5,
|
| 122 |
+
"LABEL_6": 6,
|
| 123 |
+
"LABEL_7": 7,
|
| 124 |
+
"LABEL_8": 8,
|
| 125 |
+
"LABEL_9": 9
|
| 126 |
+
},
|
| 127 |
+
"layer_norm_eps": 1e-05,
|
| 128 |
+
"layerdrop": 0.0,
|
| 129 |
+
"mask_channel_length": 10,
|
| 130 |
+
"mask_channel_min_space": 1,
|
| 131 |
+
"mask_channel_other": 0.0,
|
| 132 |
+
"mask_channel_prob": 0.0,
|
| 133 |
+
"mask_channel_selection": "static",
|
| 134 |
+
"mask_feature_length": 10,
|
| 135 |
+
"mask_feature_min_masks": 0,
|
| 136 |
+
"mask_feature_prob": 0.0,
|
| 137 |
+
"mask_time_length": 10,
|
| 138 |
+
"mask_time_min_masks": 2,
|
| 139 |
+
"mask_time_min_space": 1,
|
| 140 |
+
"mask_time_other": 0.0,
|
| 141 |
+
"mask_time_prob": 0.05,
|
| 142 |
+
"mask_time_selection": "static",
|
| 143 |
+
"model_type": "wav2vec2",
|
| 144 |
+
"no_mask_channel_overlap": false,
|
| 145 |
+
"no_mask_time_overlap": false,
|
| 146 |
+
"num_adapter_layers": 3,
|
| 147 |
+
"num_attention_heads": 12,
|
| 148 |
+
"num_codevector_groups": 2,
|
| 149 |
+
"num_codevectors_per_group": 320,
|
| 150 |
+
"num_conv_pos_embedding_groups": 16,
|
| 151 |
+
"num_conv_pos_embeddings": 128,
|
| 152 |
+
"num_feat_extract_layers": 7,
|
| 153 |
+
"num_hidden_layers": 12,
|
| 154 |
+
"num_negatives": 100,
|
| 155 |
+
"output_hidden_size": 768,
|
| 156 |
+
"pad_token_id": 0,
|
| 157 |
+
"proj_codevector_dim": 256,
|
| 158 |
+
"tdnn_dilation": [
|
| 159 |
+
1,
|
| 160 |
+
2,
|
| 161 |
+
3,
|
| 162 |
+
1,
|
| 163 |
+
1
|
| 164 |
+
],
|
| 165 |
+
"tdnn_dim": [
|
| 166 |
+
512,
|
| 167 |
+
512,
|
| 168 |
+
512,
|
| 169 |
+
512,
|
| 170 |
+
1500
|
| 171 |
+
],
|
| 172 |
+
"tdnn_kernel": [
|
| 173 |
+
5,
|
| 174 |
+
3,
|
| 175 |
+
3,
|
| 176 |
+
1,
|
| 177 |
+
1
|
| 178 |
+
],
|
| 179 |
+
"torch_dtype": "float32",
|
| 180 |
+
"transformers_version": "4.45.1",
|
| 181 |
+
"use_weighted_layer_sum": false,
|
| 182 |
+
"vocab_size": 32,
|
| 183 |
+
"xvector_output_dim": 512
|
| 184 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:2be0e5d2b93528e3c2d787eee86f649e65052a5754f68f6bb7eef6af9b031f46
|
| 3 |
+
size 378332188
|
runs/Nov24_12-27-33_5f22219c57ef/events.out.tfevents.1732451497.5f22219c57ef.30.0
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:88d48dee3d077354c50ee2c4461a7984f41dbb2eabe9c398d530e723eace2343
|
| 3 |
+
size 22621
|
runs/Nov24_12-27-33_5f22219c57ef/events.out.tfevents.1732452986.5f22219c57ef.30.1
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b194a6acb045939c989ce754981e4c2a483306a86efdb13229ebf95ef5e2d3e0
|
| 3 |
+
size 457
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:e04f28f3c88691f18d55c1573c355c1e90c1e6b1cf7e0b74110c7a23acf3ad5d
|
| 3 |
+
size 5176
|