This is a implementation of SpecAugment that speech data augmentation method which directly process the spectrogram with Tensorflow, introduced by Google Brain[1]. This is currently under the Apache 2.0, Please feel free to use for your project. Enjoy!
First, you need to have python 3 installed along with Tensorflow.
Next, you need to install some audio libraries work properly. To install the requirement packages. Run the following command:
pip install -r requirements.txt
And then, run the specAugment.py program. It modifies the spectrogram by warping it in the time direction, masking blocks of consecutive frequency channels, and masking blocks of utterances in time.
python spec_augment_test.py
In test code, we using one of the LibriSpeech dataset.