rolczynski / Automatic-Speech-Recognition

🎧 Automatic Speech Recognition: DeepSpeech & Seq2Seq (TensorFlow)
GNU Affero General Public License v3.0
223 stars 64 forks source link

CtcPipeline not implemented correctly #16

Closed shahinkl closed 4 years ago

shahinkl commented 4 years ago

def fit(self, dataset: dataset.Dataset, dev_dataset: dataset.Dataset, augmentation: augmentation.Augmentation = None, prepared_features: bool = False, **kwargs) -> keras.callbacks.History: """ Get ready data, compile and train a model. """ dataset = self.wrap_preprocess(dataset) dev_dataset = self.wrap_preprocess(dev_dataset) if not self._model.optimizer: # a loss function and an optimizer self.compile_model() # have to be set before the training return self._model.fit(dataset, validation_data=dev_dataset, **kwargs)

from example configuration (examples/use_augmentation.py) pipeline.fit(dataset, dev_dataset, epochs=25, augmentation=spec_augment)

SpecAugment is passed in the pipeline.fit() method, but never used.

rolczynski commented 4 years ago

Hey, you have absolutely right. We should pass **kwargs to the wrap_preprocess. Could you make a PR with the hotfix? I would really appreciate.