How To Build An Arabic Audio Classifier Using TensorFlow?

Eman Elrefai
5 min read6 days ago

In this tutorial, you’ll learn how to deal with audio, train the model, test it, and develop using tensorflowjs. Are you eager to start? Let’s start!

Image by https://ai.thestempedia.com

The Arabic Speech Corpus Dataset

This is the dataset used in building the project. When you check their website, you have two versions of the dataset: one is a sample with only 20 recordings and another is the complete dataset with about 9992 audio files.

Screenshot by Author

For each audio, you’ll find only one recorded word by 50 native speakers who repeated each word 10 times for 20 words in total. So the naming for the audio file can tell you about this information. For example this audio name: S01.02.05.wav. The first part is the speaker number from 1 to 50: S01, the second part is the repetition number from 1 to 10: 02 and the last part is the word number from 1 to 20: 05 . You can check the README file as well for more details.

Let’s Code!

Import all required libraries:

  • You’ll use the tensorflow_io for reading wave files. This extension package is from Tensorflow to handle…

--

--