KeyError: 'input_features' when running trainer.train() in Fine Tune Whisper
I am working on Fine-Tune Whisper For Multilingual ASR withTransformers by Sanchit Gandhi by following his blog, When I am training the model at trainer.train(). I am getting this error││ /usr/local/lib/python3.10/dist-packages/transformers/trainer.py:1539 in train                    ││                                                                                                  ││   1536 │   │   inner_training_loop = find_executable_batch_size(                                 ││   1537 │   │   │   self._inner_training_loop, self._train_batch_size, args.auto_find_batch_size  ││   1538 │   │   )                                                                                 ││ ❱ 1539 │   │   return inner_training_loop(                                                       ││   1540 │   │   │   args=args,                                                                    ││   1541 │   │   │   resume_from_checkpoint=resume_from_checkpoint,                                ││   1542 │   │   │   trial=trial,                                                                  ││                                                                                                  ││ /usr/local/lib/python3.10/dist-packages/transformers/trainer.py:1779 in _inner_training_loop     ││                                                                                                  ││   1776 │   │   │   │   rng_to_sync = True                                                        ││   1777 │   │   │                                                                                 ││   1778 │   │   │   step = -1                                                                     ││ ❱ 1779 │   │   │   for step, inputs in enumerate(epoch_iterator):                                ││   1780 │   │   │   │   total_batched_samples += 1                                                ││   1781 │   │   │   │   if rng_to_sync:                                                           ││   1782 │   │   │   │   │   self._load_rng_state(resume_from_checkpoint)                          ││                                                                                                  ││ /usr/local/lib/python3.10/dist-packages/accelerate/data_loader.py:377 initer││                                                                                                  ││   374 │   │   dataloader_iter = super().iter()                                               ││   375 │   │   # We iterate one batch ahead to check when we are at the end                       ││   376 │   │   try:                                                                               ││ ❱ 377 │   │   │   current_batch = next(dataloader_iter)                                          ││   378 │   │   except StopIteration:                                                              ││   379 │   │   │   yield                                                                          ││   380                                                                                            ││                                                                                                  ││ /usr/local/lib/python3.10/dist-packages/torch/utils/data/dataloader.py:633 innext││                                                                                                  ││    630 │   │   │   if self._sampler_iter is None:                                                ││    631 │   │   │   │   # TODO(Bug in dataloader iterator found by mypy · Issue #76750 · pytorch/pytorch · GitHub)                   ││    632 │   │   │   │   self._reset()  # type: ignore[call-arg]                                   ││ ❱  633 │   │   │   data = self._next_data()                                                      ││    634 │   │   │   self._num_yielded += 1                                                        ││    635 │   │   │   if self._dataset_kind == _DatasetKind.Iterable and \                          ││    636 │   │   │   │   │   self._IterableDataset_len_called is not None and \                    ││                                                                                                  ││ /usr/local/lib/python3.10/dist-packages/torch/utils/data/dataloader.py:677 in _next_data         ││                                                                                                  ││    674 │                                                                                         ││    675 │   def _next_data(self):                                                                 ││    676 │   │   index = self._next_index()  # may raise StopIteration                             ││ ❱  677 │   │   data = self._dataset_fetcher.fetch(index)  # may raise StopIteration              ││    678 │   │   if self._pin_memory:                                                              ││    679 │   │   │   data = _utils.pin_memory.pin_memory(data, self._pin_memory_device)            ││    680 │   │   return data                                                                       ││                                                                                                  ││ /usr/local/lib/python3.10/dist-packages/torch/utils/data/_utils/fetch.py:54 in fetch             ││                                                                                                  ││   51 │   │   │   │   data = [self.dataset[idx] for idx in possibly_batched_index]                ││   52 │   │   else:                                                                               ││   53 │   │   │   data = self.dataset[possibly_batched_index]                                     ││ ❱ 54 │   │   return self.collate_fn(data)                                                        ││   55                                                                                             ││ incall:13                                                                                   ││ in :13                                                                                 │╰──────────────────────────────────────────────────────────────────────────────────────────────────╯KeyError: ‘input_features’I couldn’t find the solution for this, please help me to solve this isse.Thanks in advance
2023-07-28T09:13:30Z
Hi, have you got any solution?
2023-09-24T13:07:11Z
No didn’t get solution
2023-12-11T17:06:29Z
hello did you find the solution ?