Skip to content

A Speaker Classification Project which uses a binary classification method.

License

Notifications You must be signed in to change notification settings

Karpmaster/Binary_Speaker_Classification

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Binary_Speaker_Classification

A Speaker Classification Project which uses a binary classification method.

Introduction

Since this project is assumed to be used on a security door lock system, an Multi-class(Softmax) structure can be quite akward. If we use an softmax activation function in the output layer and apply a category cross entropy loss function, anything within the label of the dataset can surely be classified.

Simple example: Assume we contain features of dog, cat, frog in our dataset. Train our model with this dataset. Now we user a another dog file. The expected predict result should be: dog. If we use a cat file, we should get a cat etc. No problem? What if now I purposely use a duck file to test the model. But the we don't have class(label) that is duck. What is the result?

Probably the frog class since the sound of the frog is the most similar(least loss) to a duck. a.k.a. This kind of Multi-class classification cannot regonize things which is not within the dataset. (Unless, you add a forth class, assume: other, which contians all kinds of other sounds of different animals.)

Method

In a security system, You definitely want to recognize the outsiders. So in this project, I try do change it to a One-vs-All(or One-vs-Rest) method. We can use multiple binary classification model to identify outsiders and also find the correct class.

Back to the dog, cat, frog example: Now we supposedly have three binary model for each classes(labels). First we use a dog file, it should work like:

  1. Is it a dog? Yes.
  2. Is it a cat? No.
  3. Is it a frog? No.
  4. ANS: dog.

Now if use the duck file, it should work likes this:

  1. Is it a dog? No.
  2. Is it a cat? No.
  3. Is it a frog? No.
  4. ANS: Belongs to none of the classes.

Result

Show out a binary classifier can be quite succes and suitable for my security door lock system.

However, for now, I have to manually change the cureent user variable to make the correct One-vs-All dataset format. Might use the os.path.walk function in python to improve the automation flow.

About

A Speaker Classification Project which uses a binary classification method.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages