EBAG
EBAG

Reputation: 22561

Search an Audio inside another Audio in C# or C++

Suppose there is a sample audio file that contains up to 10 simple words

"One Two Three .... Ten"

and there is 1 second silence between each number in the audio file.

I want to check to see if the audio file contains keyword "Two" for example. Please note that I have the keyword "Two" voice file and it's the same exact voice from the master voice file, but It may contain some noise.

Is there a way for me to search the voice "Two" inside that bigger audio file and find the occurrence time?

Upvotes: 1

Views: 1029

Answers (2)

Felix Av
Felix Av

Reputation: 1254

Since there's no provided code, i'll just give you the idea how to proceed, hope it'll help.

First you have to split your file to 10 different audio files according to silence (I'm sure there are libraries that will help you do that).

Then you can send the file to google voice recognition api, and get a string as a result, which will contain the string according to the voice in the file.

EDIT: Please refer to: https://googlespeechtotext.codeplex.com/

How to use google speech recognition api in c#?

Upvotes: 2

Syed Danish Ali
Syed Danish Ali

Reputation: 391

Why don't you just work out to convert both the audio samples into some bits or signal formats and check if they both have a some common strings.

Some of the links you should check before going any further just to work out with audio in .Net:

http://crsouza.com/2009/08/converting-audio-bit-depths-in-c/
https://cscore.codeplex.com/
http://www.codeproject.com/Articles/501521/How-to-convert-between-most-audio-formats-in-NET

Let me know if you can work this out.

Upvotes: 0

Related Questions