End of training
Browse files
fine-tune-whisper-streaming.ipynb
CHANGED
@@ -1064,8 +1064,8 @@
|
|
1064 |
"\n",
|
1065 |
" <div>\n",
|
1066 |
" \n",
|
1067 |
-
" <progress value='
|
1068 |
-
" [
|
1069 |
" </div>\n",
|
1070 |
" <table border=\"1\" class=\"dataframe\">\n",
|
1071 |
" <thead>\n",
|
@@ -1083,6 +1083,12 @@
|
|
1083 |
" <td>0.257123</td>\n",
|
1084 |
" <td>13.282745</td>\n",
|
1085 |
" </tr>\n",
|
|
|
|
|
|
|
|
|
|
|
|
|
1086 |
" </tbody>\n",
|
1087 |
"</table><p>"
|
1088 |
],
|
@@ -1117,8 +1123,51 @@
|
|
1117 |
" Num examples: Unknown\n",
|
1118 |
" Batch size = 8\n",
|
1119 |
"Reading metadata...: 15003it [00:00, 39593.28it/s]\n",
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1120 |
"The following columns in the evaluation set don't have a corresponding argument in `WhisperForConditionalGeneration.forward` and have been ignored: input_length. If input_length are not expected by `WhisperForConditionalGeneration.forward`, you can safely ignore this message.\n"
|
1121 |
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1122 |
}
|
1123 |
],
|
1124 |
"source": [
|
@@ -1147,7 +1196,7 @@
|
|
1147 |
},
|
1148 |
{
|
1149 |
"cell_type": "code",
|
1150 |
-
"execution_count":
|
1151 |
"id": "6dd0e310-9b07-4133-ac14-2ed2d7524e22",
|
1152 |
"metadata": {},
|
1153 |
"outputs": [],
|
@@ -1173,10 +1222,24 @@
|
|
1173 |
},
|
1174 |
{
|
1175 |
"cell_type": "code",
|
1176 |
-
"execution_count":
|
1177 |
"id": "95737cda-c5dd-4887-a4d0-dfcb0d61d977",
|
1178 |
"metadata": {},
|
1179 |
-
"outputs": [
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1180 |
"source": [
|
1181 |
"trainer.push_to_hub(**kwargs)"
|
1182 |
]
|
|
|
1064 |
"\n",
|
1065 |
" <div>\n",
|
1066 |
" \n",
|
1067 |
+
" <progress value='3001' max='5000' style='width:300px; height:20px; vertical-align: middle;'></progress>\n",
|
1068 |
+
" [3001/5000 8:52:48 < 5:55:08, 0.09 it/s, Epoch 1.12/9223372036854775807]\n",
|
1069 |
" </div>\n",
|
1070 |
" <table border=\"1\" class=\"dataframe\">\n",
|
1071 |
" <thead>\n",
|
|
|
1083 |
" <td>0.257123</td>\n",
|
1084 |
" <td>13.282745</td>\n",
|
1085 |
" </tr>\n",
|
1086 |
+
" <tr>\n",
|
1087 |
+
" <td>2000</td>\n",
|
1088 |
+
" <td>0.149400</td>\n",
|
1089 |
+
" <td>0.211123</td>\n",
|
1090 |
+
" <td>10.135153</td>\n",
|
1091 |
+
" </tr>\n",
|
1092 |
" </tbody>\n",
|
1093 |
"</table><p>"
|
1094 |
],
|
|
|
1123 |
" Num examples: Unknown\n",
|
1124 |
" Batch size = 8\n",
|
1125 |
"Reading metadata...: 15003it [00:00, 39593.28it/s]\n",
|
1126 |
+
"The following columns in the evaluation set don't have a corresponding argument in `WhisperForConditionalGeneration.forward` and have been ignored: input_length. If input_length are not expected by `WhisperForConditionalGeneration.forward`, you can safely ignore this message.\n",
|
1127 |
+
"Saving model checkpoint to ./checkpoint-2000\n",
|
1128 |
+
"Configuration saved in ./checkpoint-2000/config.json\n",
|
1129 |
+
"Model weights saved in ./checkpoint-2000/pytorch_model.bin\n",
|
1130 |
+
"Feature extractor saved in ./checkpoint-2000/preprocessor_config.json\n",
|
1131 |
+
"tokenizer config file saved in ./checkpoint-2000/tokenizer_config.json\n",
|
1132 |
+
"Special tokens file saved in ./checkpoint-2000/special_tokens_map.json\n",
|
1133 |
+
"added tokens file saved in ./checkpoint-2000/added_tokens.json\n",
|
1134 |
+
"Feature extractor saved in ./preprocessor_config.json\n",
|
1135 |
+
"tokenizer config file saved in ./tokenizer_config.json\n",
|
1136 |
+
"Special tokens file saved in ./special_tokens_map.json\n",
|
1137 |
+
"added tokens file saved in ./added_tokens.json\n",
|
1138 |
+
"Reading metadata...: 152609it [00:04, 34307.28it/s]\n",
|
1139 |
+
"***** Running Evaluation *****\n",
|
1140 |
+
" Num examples: Unknown\n",
|
1141 |
+
" Batch size = 8\n",
|
1142 |
+
"Reading metadata...: 15003it [00:00, 38981.36it/s]\n",
|
1143 |
"The following columns in the evaluation set don't have a corresponding argument in `WhisperForConditionalGeneration.forward` and have been ignored: input_length. If input_length are not expected by `WhisperForConditionalGeneration.forward`, you can safely ignore this message.\n"
|
1144 |
]
|
1145 |
+
},
|
1146 |
+
{
|
1147 |
+
"ename": "KeyboardInterrupt",
|
1148 |
+
"evalue": "",
|
1149 |
+
"output_type": "error",
|
1150 |
+
"traceback": [
|
1151 |
+
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
|
1152 |
+
"\u001b[0;31mKeyboardInterrupt\u001b[0m Traceback (most recent call last)",
|
1153 |
+
"Cell \u001b[0;32mIn[22], line 1\u001b[0m\n\u001b[0;32m----> 1\u001b[0m trainer\u001b[39m.\u001b[39;49mtrain()\n",
|
1154 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/trainer.py:1536\u001b[0m, in \u001b[0;36mTrainer.train\u001b[0;34m(self, resume_from_checkpoint, trial, ignore_keys_for_eval, **kwargs)\u001b[0m\n\u001b[1;32m 1531\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mmodel_wrapped \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mmodel\n\u001b[1;32m 1533\u001b[0m inner_training_loop \u001b[39m=\u001b[39m find_executable_batch_size(\n\u001b[1;32m 1534\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_inner_training_loop, \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_train_batch_size, args\u001b[39m.\u001b[39mauto_find_batch_size\n\u001b[1;32m 1535\u001b[0m )\n\u001b[0;32m-> 1536\u001b[0m \u001b[39mreturn\u001b[39;00m inner_training_loop(\n\u001b[1;32m 1537\u001b[0m args\u001b[39m=\u001b[39;49margs,\n\u001b[1;32m 1538\u001b[0m resume_from_checkpoint\u001b[39m=\u001b[39;49mresume_from_checkpoint,\n\u001b[1;32m 1539\u001b[0m trial\u001b[39m=\u001b[39;49mtrial,\n\u001b[1;32m 1540\u001b[0m ignore_keys_for_eval\u001b[39m=\u001b[39;49mignore_keys_for_eval,\n\u001b[1;32m 1541\u001b[0m )\n",
|
1155 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/trainer.py:1861\u001b[0m, in \u001b[0;36mTrainer._inner_training_loop\u001b[0;34m(self, batch_size, args, resume_from_checkpoint, trial, ignore_keys_for_eval)\u001b[0m\n\u001b[1;32m 1858\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mstate\u001b[39m.\u001b[39mepoch \u001b[39m=\u001b[39m epoch \u001b[39m+\u001b[39m (step \u001b[39m+\u001b[39m \u001b[39m1\u001b[39m) \u001b[39m/\u001b[39m steps_in_epoch\n\u001b[1;32m 1859\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcontrol \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcallback_handler\u001b[39m.\u001b[39mon_step_end(args, \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mstate, \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcontrol)\n\u001b[0;32m-> 1861\u001b[0m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49m_maybe_log_save_evaluate(tr_loss, model, trial, epoch, ignore_keys_for_eval)\n\u001b[1;32m 1862\u001b[0m \u001b[39melse\u001b[39;00m:\n\u001b[1;32m 1863\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcontrol \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcallback_handler\u001b[39m.\u001b[39mon_substep_end(args, \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mstate, \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcontrol)\n",
|
1156 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/trainer.py:2124\u001b[0m, in \u001b[0;36mTrainer._maybe_log_save_evaluate\u001b[0;34m(self, tr_loss, model, trial, epoch, ignore_keys_for_eval)\u001b[0m\n\u001b[1;32m 2118\u001b[0m metrics \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mevaluate(\n\u001b[1;32m 2119\u001b[0m eval_dataset\u001b[39m=\u001b[39meval_dataset,\n\u001b[1;32m 2120\u001b[0m ignore_keys\u001b[39m=\u001b[39mignore_keys_for_eval,\n\u001b[1;32m 2121\u001b[0m metric_key_prefix\u001b[39m=\u001b[39m\u001b[39mf\u001b[39m\u001b[39m\"\u001b[39m\u001b[39meval_\u001b[39m\u001b[39m{\u001b[39;00meval_dataset_name\u001b[39m}\u001b[39;00m\u001b[39m\"\u001b[39m,\n\u001b[1;32m 2122\u001b[0m )\n\u001b[1;32m 2123\u001b[0m \u001b[39melse\u001b[39;00m:\n\u001b[0;32m-> 2124\u001b[0m metrics \u001b[39m=\u001b[39m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mevaluate(ignore_keys\u001b[39m=\u001b[39;49mignore_keys_for_eval)\n\u001b[1;32m 2125\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_report_to_hp_search(trial, \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mstate\u001b[39m.\u001b[39mglobal_step, metrics)\n\u001b[1;32m 2127\u001b[0m \u001b[39mif\u001b[39;00m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcontrol\u001b[39m.\u001b[39mshould_save:\n",
|
1157 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/trainer_seq2seq.py:78\u001b[0m, in \u001b[0;36mSeq2SeqTrainer.evaluate\u001b[0;34m(self, eval_dataset, ignore_keys, metric_key_prefix, **gen_kwargs)\u001b[0m\n\u001b[1;32m 73\u001b[0m gen_kwargs[\u001b[39m\"\u001b[39m\u001b[39mnum_beams\u001b[39m\u001b[39m\"\u001b[39m] \u001b[39m=\u001b[39m (\n\u001b[1;32m 74\u001b[0m gen_kwargs[\u001b[39m\"\u001b[39m\u001b[39mnum_beams\u001b[39m\u001b[39m\"\u001b[39m] \u001b[39mif\u001b[39;00m gen_kwargs\u001b[39m.\u001b[39mget(\u001b[39m\"\u001b[39m\u001b[39mnum_beams\u001b[39m\u001b[39m\"\u001b[39m) \u001b[39mis\u001b[39;00m \u001b[39mnot\u001b[39;00m \u001b[39mNone\u001b[39;00m \u001b[39melse\u001b[39;00m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39margs\u001b[39m.\u001b[39mgeneration_num_beams\n\u001b[1;32m 75\u001b[0m )\n\u001b[1;32m 76\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_gen_kwargs \u001b[39m=\u001b[39m gen_kwargs\n\u001b[0;32m---> 78\u001b[0m \u001b[39mreturn\u001b[39;00m \u001b[39msuper\u001b[39;49m()\u001b[39m.\u001b[39;49mevaluate(eval_dataset, ignore_keys\u001b[39m=\u001b[39;49mignore_keys, metric_key_prefix\u001b[39m=\u001b[39;49mmetric_key_prefix)\n",
|
1158 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/trainer.py:2820\u001b[0m, in \u001b[0;36mTrainer.evaluate\u001b[0;34m(self, eval_dataset, ignore_keys, metric_key_prefix)\u001b[0m\n\u001b[1;32m 2817\u001b[0m start_time \u001b[39m=\u001b[39m time\u001b[39m.\u001b[39mtime()\n\u001b[1;32m 2819\u001b[0m eval_loop \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mprediction_loop \u001b[39mif\u001b[39;00m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39margs\u001b[39m.\u001b[39muse_legacy_prediction_loop \u001b[39melse\u001b[39;00m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mevaluation_loop\n\u001b[0;32m-> 2820\u001b[0m output \u001b[39m=\u001b[39m eval_loop(\n\u001b[1;32m 2821\u001b[0m eval_dataloader,\n\u001b[1;32m 2822\u001b[0m description\u001b[39m=\u001b[39;49m\u001b[39m\"\u001b[39;49m\u001b[39mEvaluation\u001b[39;49m\u001b[39m\"\u001b[39;49m,\n\u001b[1;32m 2823\u001b[0m \u001b[39m# No point gathering the predictions if there are no metrics, otherwise we defer to\u001b[39;49;00m\n\u001b[1;32m 2824\u001b[0m \u001b[39m# self.args.prediction_loss_only\u001b[39;49;00m\n\u001b[1;32m 2825\u001b[0m prediction_loss_only\u001b[39m=\u001b[39;49m\u001b[39mTrue\u001b[39;49;00m \u001b[39mif\u001b[39;49;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mcompute_metrics \u001b[39mis\u001b[39;49;00m \u001b[39mNone\u001b[39;49;00m \u001b[39melse\u001b[39;49;00m \u001b[39mNone\u001b[39;49;00m,\n\u001b[1;32m 2826\u001b[0m ignore_keys\u001b[39m=\u001b[39;49mignore_keys,\n\u001b[1;32m 2827\u001b[0m metric_key_prefix\u001b[39m=\u001b[39;49mmetric_key_prefix,\n\u001b[1;32m 2828\u001b[0m )\n\u001b[1;32m 2830\u001b[0m total_batch_size \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39margs\u001b[39m.\u001b[39meval_batch_size \u001b[39m*\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39margs\u001b[39m.\u001b[39mworld_size\n\u001b[1;32m 2831\u001b[0m \u001b[39mif\u001b[39;00m \u001b[39mf\u001b[39m\u001b[39m\"\u001b[39m\u001b[39m{\u001b[39;00mmetric_key_prefix\u001b[39m}\u001b[39;00m\u001b[39m_jit_compilation_time\u001b[39m\u001b[39m\"\u001b[39m \u001b[39min\u001b[39;00m output\u001b[39m.\u001b[39mmetrics:\n",
|
1159 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/trainer.py:3109\u001b[0m, in \u001b[0;36mTrainer.evaluation_loop\u001b[0;34m(self, dataloader, description, prediction_loss_only, ignore_keys, metric_key_prefix)\u001b[0m\n\u001b[1;32m 3105\u001b[0m metrics \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mcompute_metrics(\n\u001b[1;32m 3106\u001b[0m EvalPrediction(predictions\u001b[39m=\u001b[39mall_preds, label_ids\u001b[39m=\u001b[39mall_labels, inputs\u001b[39m=\u001b[39mall_inputs)\n\u001b[1;32m 3107\u001b[0m )\n\u001b[1;32m 3108\u001b[0m \u001b[39melse\u001b[39;00m:\n\u001b[0;32m-> 3109\u001b[0m metrics \u001b[39m=\u001b[39m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mcompute_metrics(EvalPrediction(predictions\u001b[39m=\u001b[39;49mall_preds, label_ids\u001b[39m=\u001b[39;49mall_labels))\n\u001b[1;32m 3110\u001b[0m \u001b[39melse\u001b[39;00m:\n\u001b[1;32m 3111\u001b[0m metrics \u001b[39m=\u001b[39m {}\n",
|
1160 |
+
"Cell \u001b[0;32mIn[15], line 13\u001b[0m, in \u001b[0;36mcompute_metrics\u001b[0;34m(pred)\u001b[0m\n\u001b[1;32m 11\u001b[0m \u001b[39m# we do not want to group tokens when computing the metrics\u001b[39;00m\n\u001b[1;32m 12\u001b[0m pred_str \u001b[39m=\u001b[39m processor\u001b[39m.\u001b[39mtokenizer\u001b[39m.\u001b[39mbatch_decode(pred_ids, skip_special_tokens\u001b[39m=\u001b[39m\u001b[39mTrue\u001b[39;00m)\n\u001b[0;32m---> 13\u001b[0m label_str \u001b[39m=\u001b[39m processor\u001b[39m.\u001b[39;49mtokenizer\u001b[39m.\u001b[39;49mbatch_decode(label_ids, skip_special_tokens\u001b[39m=\u001b[39;49m\u001b[39mTrue\u001b[39;49;00m)\n\u001b[1;32m 15\u001b[0m \u001b[39mif\u001b[39;00m do_normalize_eval:\n\u001b[1;32m 16\u001b[0m pred_str \u001b[39m=\u001b[39m [normalizer(pred) \u001b[39mfor\u001b[39;00m pred \u001b[39min\u001b[39;00m pred_str]\n",
|
1161 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils_base.py:3429\u001b[0m, in \u001b[0;36mPreTrainedTokenizerBase.batch_decode\u001b[0;34m(self, sequences, skip_special_tokens, clean_up_tokenization_spaces, **kwargs)\u001b[0m\n\u001b[1;32m 3406\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mbatch_decode\u001b[39m(\n\u001b[1;32m 3407\u001b[0m \u001b[39mself\u001b[39m,\n\u001b[1;32m 3408\u001b[0m sequences: Union[List[\u001b[39mint\u001b[39m], List[List[\u001b[39mint\u001b[39m]], \u001b[39m\"\u001b[39m\u001b[39mnp.ndarray\u001b[39m\u001b[39m\"\u001b[39m, \u001b[39m\"\u001b[39m\u001b[39mtorch.Tensor\u001b[39m\u001b[39m\"\u001b[39m, \u001b[39m\"\u001b[39m\u001b[39mtf.Tensor\u001b[39m\u001b[39m\"\u001b[39m],\n\u001b[0;32m (...)\u001b[0m\n\u001b[1;32m 3411\u001b[0m \u001b[39m*\u001b[39m\u001b[39m*\u001b[39mkwargs\n\u001b[1;32m 3412\u001b[0m ) \u001b[39m-\u001b[39m\u001b[39m>\u001b[39m List[\u001b[39mstr\u001b[39m]:\n\u001b[1;32m 3413\u001b[0m \u001b[39m\"\"\"\u001b[39;00m\n\u001b[1;32m 3414\u001b[0m \u001b[39m Convert a list of lists of token ids into a list of strings by calling decode.\u001b[39;00m\n\u001b[1;32m 3415\u001b[0m \n\u001b[0;32m (...)\u001b[0m\n\u001b[1;32m 3427\u001b[0m \u001b[39m `List[str]`: The list of decoded sentences.\u001b[39;00m\n\u001b[1;32m 3428\u001b[0m \u001b[39m \"\"\"\u001b[39;00m\n\u001b[0;32m-> 3429\u001b[0m \u001b[39mreturn\u001b[39;00m [\n\u001b[1;32m 3430\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mdecode(\n\u001b[1;32m 3431\u001b[0m seq,\n\u001b[1;32m 3432\u001b[0m skip_special_tokens\u001b[39m=\u001b[39mskip_special_tokens,\n\u001b[1;32m 3433\u001b[0m clean_up_tokenization_spaces\u001b[39m=\u001b[39mclean_up_tokenization_spaces,\n\u001b[1;32m 3434\u001b[0m \u001b[39m*\u001b[39m\u001b[39m*\u001b[39mkwargs,\n\u001b[1;32m 3435\u001b[0m )\n\u001b[1;32m 3436\u001b[0m \u001b[39mfor\u001b[39;00m seq \u001b[39min\u001b[39;00m sequences\n\u001b[1;32m 3437\u001b[0m ]\n",
|
1162 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils_base.py:3430\u001b[0m, in \u001b[0;36m<listcomp>\u001b[0;34m(.0)\u001b[0m\n\u001b[1;32m 3406\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mbatch_decode\u001b[39m(\n\u001b[1;32m 3407\u001b[0m \u001b[39mself\u001b[39m,\n\u001b[1;32m 3408\u001b[0m sequences: Union[List[\u001b[39mint\u001b[39m], List[List[\u001b[39mint\u001b[39m]], \u001b[39m\"\u001b[39m\u001b[39mnp.ndarray\u001b[39m\u001b[39m\"\u001b[39m, \u001b[39m\"\u001b[39m\u001b[39mtorch.Tensor\u001b[39m\u001b[39m\"\u001b[39m, \u001b[39m\"\u001b[39m\u001b[39mtf.Tensor\u001b[39m\u001b[39m\"\u001b[39m],\n\u001b[0;32m (...)\u001b[0m\n\u001b[1;32m 3411\u001b[0m \u001b[39m*\u001b[39m\u001b[39m*\u001b[39mkwargs\n\u001b[1;32m 3412\u001b[0m ) \u001b[39m-\u001b[39m\u001b[39m>\u001b[39m List[\u001b[39mstr\u001b[39m]:\n\u001b[1;32m 3413\u001b[0m \u001b[39m\"\"\"\u001b[39;00m\n\u001b[1;32m 3414\u001b[0m \u001b[39m Convert a list of lists of token ids into a list of strings by calling decode.\u001b[39;00m\n\u001b[1;32m 3415\u001b[0m \n\u001b[0;32m (...)\u001b[0m\n\u001b[1;32m 3427\u001b[0m \u001b[39m `List[str]`: The list of decoded sentences.\u001b[39;00m\n\u001b[1;32m 3428\u001b[0m \u001b[39m \"\"\"\u001b[39;00m\n\u001b[1;32m 3429\u001b[0m \u001b[39mreturn\u001b[39;00m [\n\u001b[0;32m-> 3430\u001b[0m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mdecode(\n\u001b[1;32m 3431\u001b[0m seq,\n\u001b[1;32m 3432\u001b[0m skip_special_tokens\u001b[39m=\u001b[39;49mskip_special_tokens,\n\u001b[1;32m 3433\u001b[0m clean_up_tokenization_spaces\u001b[39m=\u001b[39;49mclean_up_tokenization_spaces,\n\u001b[1;32m 3434\u001b[0m \u001b[39m*\u001b[39;49m\u001b[39m*\u001b[39;49mkwargs,\n\u001b[1;32m 3435\u001b[0m )\n\u001b[1;32m 3436\u001b[0m \u001b[39mfor\u001b[39;00m seq \u001b[39min\u001b[39;00m sequences\n\u001b[1;32m 3437\u001b[0m ]\n",
|
1163 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils_base.py:3468\u001b[0m, in \u001b[0;36mPreTrainedTokenizerBase.decode\u001b[0;34m(self, token_ids, skip_special_tokens, clean_up_tokenization_spaces, **kwargs)\u001b[0m\n\u001b[1;32m 3465\u001b[0m \u001b[39m# Convert inputs to python lists\u001b[39;00m\n\u001b[1;32m 3466\u001b[0m token_ids \u001b[39m=\u001b[39m to_py_obj(token_ids)\n\u001b[0;32m-> 3468\u001b[0m \u001b[39mreturn\u001b[39;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49m_decode(\n\u001b[1;32m 3469\u001b[0m token_ids\u001b[39m=\u001b[39;49mtoken_ids,\n\u001b[1;32m 3470\u001b[0m skip_special_tokens\u001b[39m=\u001b[39;49mskip_special_tokens,\n\u001b[1;32m 3471\u001b[0m clean_up_tokenization_spaces\u001b[39m=\u001b[39;49mclean_up_tokenization_spaces,\n\u001b[1;32m 3472\u001b[0m \u001b[39m*\u001b[39;49m\u001b[39m*\u001b[39;49mkwargs,\n\u001b[1;32m 3473\u001b[0m )\n",
|
1164 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/models/whisper/tokenization_whisper.py:496\u001b[0m, in \u001b[0;36mWhisperTokenizer._decode\u001b[0;34m(self, token_ids, skip_special_tokens, normalize, **kwargs)\u001b[0m\n\u001b[1;32m 491\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39m_decode\u001b[39m(\n\u001b[1;32m 492\u001b[0m \u001b[39mself\u001b[39m, token_ids: Union[\u001b[39mint\u001b[39m, List[\u001b[39mint\u001b[39m]], skip_special_tokens: \u001b[39mbool\u001b[39m \u001b[39m=\u001b[39m \u001b[39mFalse\u001b[39;00m, normalize: \u001b[39mbool\u001b[39m \u001b[39m=\u001b[39m \u001b[39mFalse\u001b[39;00m, \u001b[39m*\u001b[39m\u001b[39m*\u001b[39mkwargs\n\u001b[1;32m 493\u001b[0m ) \u001b[39m-\u001b[39m\u001b[39m>\u001b[39m \u001b[39mstr\u001b[39m:\n\u001b[1;32m 494\u001b[0m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39m_decode_use_source_tokenizer \u001b[39m=\u001b[39m kwargs\u001b[39m.\u001b[39mpop(\u001b[39m\"\u001b[39m\u001b[39muse_source_tokenizer\u001b[39m\u001b[39m\"\u001b[39m, \u001b[39mFalse\u001b[39;00m)\n\u001b[0;32m--> 496\u001b[0m filtered_tokens \u001b[39m=\u001b[39m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mconvert_ids_to_tokens(token_ids, skip_special_tokens\u001b[39m=\u001b[39;49mskip_special_tokens)\n\u001b[1;32m 498\u001b[0m \u001b[39m# To avoid mixing byte-level and unicode for byte-level BPT\u001b[39;00m\n\u001b[1;32m 499\u001b[0m \u001b[39m# we need to build string separately for added tokens and byte-level tokens\u001b[39;00m\n\u001b[1;32m 500\u001b[0m \u001b[39m# cf. https://github.com/huggingface/transformers/issues/1133\u001b[39;00m\n\u001b[1;32m 501\u001b[0m sub_texts \u001b[39m=\u001b[39m []\n",
|
1165 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils.py:907\u001b[0m, in \u001b[0;36mPreTrainedTokenizer.convert_ids_to_tokens\u001b[0;34m(self, ids, skip_special_tokens)\u001b[0m\n\u001b[1;32m 905\u001b[0m \u001b[39mfor\u001b[39;00m index \u001b[39min\u001b[39;00m ids:\n\u001b[1;32m 906\u001b[0m index \u001b[39m=\u001b[39m \u001b[39mint\u001b[39m(index)\n\u001b[0;32m--> 907\u001b[0m \u001b[39mif\u001b[39;00m skip_special_tokens \u001b[39mand\u001b[39;00m index \u001b[39min\u001b[39;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mall_special_ids:\n\u001b[1;32m 908\u001b[0m \u001b[39mcontinue\u001b[39;00m\n\u001b[1;32m 909\u001b[0m \u001b[39mif\u001b[39;00m index \u001b[39min\u001b[39;00m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39madded_tokens_decoder:\n",
|
1166 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils_base.py:1297\u001b[0m, in \u001b[0;36mSpecialTokensMixin.all_special_ids\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 1292\u001b[0m \u001b[39m@property\u001b[39m\n\u001b[1;32m 1293\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mall_special_ids\u001b[39m(\u001b[39mself\u001b[39m) \u001b[39m-\u001b[39m\u001b[39m>\u001b[39m List[\u001b[39mint\u001b[39m]:\n\u001b[1;32m 1294\u001b[0m \u001b[39m\"\"\"\u001b[39;00m\n\u001b[1;32m 1295\u001b[0m \u001b[39m `List[int]`: List the ids of the special tokens(`'<unk>'`, `'<cls>'`, etc.) mapped to class attributes.\u001b[39;00m\n\u001b[1;32m 1296\u001b[0m \u001b[39m \"\"\"\u001b[39;00m\n\u001b[0;32m-> 1297\u001b[0m all_toks \u001b[39m=\u001b[39m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mall_special_tokens\n\u001b[1;32m 1298\u001b[0m all_ids \u001b[39m=\u001b[39m \u001b[39mself\u001b[39m\u001b[39m.\u001b[39mconvert_tokens_to_ids(all_toks)\n\u001b[1;32m 1299\u001b[0m \u001b[39mreturn\u001b[39;00m all_ids\n",
|
1167 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils_base.py:1273\u001b[0m, in \u001b[0;36mSpecialTokensMixin.all_special_tokens\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 1266\u001b[0m \u001b[39m@property\u001b[39m\n\u001b[1;32m 1267\u001b[0m \u001b[39mdef\u001b[39;00m \u001b[39mall_special_tokens\u001b[39m(\u001b[39mself\u001b[39m) \u001b[39m-\u001b[39m\u001b[39m>\u001b[39m List[\u001b[39mstr\u001b[39m]:\n\u001b[1;32m 1268\u001b[0m \u001b[39m\"\"\"\u001b[39;00m\n\u001b[1;32m 1269\u001b[0m \u001b[39m `List[str]`: All the special tokens (`'<unk>'`, `'<cls>'`, etc.) mapped to class attributes.\u001b[39;00m\n\u001b[1;32m 1270\u001b[0m \n\u001b[1;32m 1271\u001b[0m \u001b[39m Convert tokens of `tokenizers.AddedToken` type to string.\u001b[39;00m\n\u001b[1;32m 1272\u001b[0m \u001b[39m \"\"\"\u001b[39;00m\n\u001b[0;32m-> 1273\u001b[0m all_toks \u001b[39m=\u001b[39m [\u001b[39mstr\u001b[39m(s) \u001b[39mfor\u001b[39;00m s \u001b[39min\u001b[39;00m \u001b[39mself\u001b[39;49m\u001b[39m.\u001b[39;49mall_special_tokens_extended]\n\u001b[1;32m 1274\u001b[0m \u001b[39mreturn\u001b[39;00m all_toks\n",
|
1168 |
+
"File \u001b[0;32m~/.env_hf/lib/python3.8/site-packages/transformers/tokenization_utils_base.py:1289\u001b[0m, in \u001b[0;36mSpecialTokensMixin.all_special_tokens_extended\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 1287\u001b[0m \u001b[39mfor\u001b[39;00m attr_value \u001b[39min\u001b[39;00m set_attr\u001b[39m.\u001b[39mvalues():\n\u001b[1;32m 1288\u001b[0m all_toks \u001b[39m=\u001b[39m all_toks \u001b[39m+\u001b[39m (\u001b[39mlist\u001b[39m(attr_value) \u001b[39mif\u001b[39;00m \u001b[39misinstance\u001b[39m(attr_value, (\u001b[39mlist\u001b[39m, \u001b[39mtuple\u001b[39m)) \u001b[39melse\u001b[39;00m [attr_value])\n\u001b[0;32m-> 1289\u001b[0m all_toks \u001b[39m=\u001b[39m \u001b[39mlist\u001b[39;49m(OrderedDict\u001b[39m.\u001b[39;49mfromkeys(all_toks))\n\u001b[1;32m 1290\u001b[0m \u001b[39mreturn\u001b[39;00m all_toks\n",
|
1169 |
+
"\u001b[0;31mKeyboardInterrupt\u001b[0m: "
|
1170 |
+
]
|
1171 |
}
|
1172 |
],
|
1173 |
"source": [
|
|
|
1196 |
},
|
1197 |
{
|
1198 |
"cell_type": "code",
|
1199 |
+
"execution_count": 23,
|
1200 |
"id": "6dd0e310-9b07-4133-ac14-2ed2d7524e22",
|
1201 |
"metadata": {},
|
1202 |
"outputs": [],
|
|
|
1222 |
},
|
1223 |
{
|
1224 |
"cell_type": "code",
|
1225 |
+
"execution_count": 24,
|
1226 |
"id": "95737cda-c5dd-4887-a4d0-dfcb0d61d977",
|
1227 |
"metadata": {},
|
1228 |
+
"outputs": [
|
1229 |
+
{
|
1230 |
+
"name": "stderr",
|
1231 |
+
"output_type": "stream",
|
1232 |
+
"text": [
|
1233 |
+
"Saving model checkpoint to ./\n",
|
1234 |
+
"Configuration saved in ./config.json\n",
|
1235 |
+
"Model weights saved in ./pytorch_model.bin\n",
|
1236 |
+
"Feature extractor saved in ./preprocessor_config.json\n",
|
1237 |
+
"tokenizer config file saved in ./tokenizer_config.json\n",
|
1238 |
+
"Special tokens file saved in ./special_tokens_map.json\n",
|
1239 |
+
"added tokens file saved in ./added_tokens.json\n"
|
1240 |
+
]
|
1241 |
+
}
|
1242 |
+
],
|
1243 |
"source": [
|
1244 |
"trainer.push_to_hub(**kwargs)"
|
1245 |
]
|
pytorch_model.bin
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 967102601
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:09880c3705dc84c52d46720d1a6ffce4418604ee7989c7eecbb4a3c34bc8c158
|
3 |
size 967102601
|
runs/Dec07_20-55-49_155-248-246-251/events.out.tfevents.1670446586.155-248-246-251.72616.0
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5abfc541666d8221aafea474e1db6a089b1ee261d20d55f07471693de7ec53ac
|
3 |
+
size 23660
|