Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-05 Thread Brian West
Kewl you can contribute via http://jira.freeswitch.org  ;)

/b

On Mar 5, 2009, at 9:41 AM, Cameron Sorlie wrote:

> In a sense, you might say I did futz with mod_vmd ... to create  
> mod_vad. There appeared to be just no (easy) way to modify the  
> internal VAD code in the FreeSWITCH core (see switch_rtp.c) to  
> identify the origins of voice activity. And rather than build into  
> mod_vmd, which is a special purpose tool, a separate module for VAD  
> seemed like a reasonable idea.
>
> In short, the mod_vad which I've written up independently monitors  
> the read and the write legs of the session it is run on, and tags  
> each VAD_TALK and VAD_NOTALK event it fires with a user-supplied  
> identification marker (a short string) for the leg which the event  
> relates to. At the moment, the VAD algorithm is dead simple, and is  
> much like the one in the core. I will be happy to submit this  
> module, in a little while, after I've had a chance to make it  
> perhaps a bit more useable outside of our own application context.
>
> Cam


___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-05 Thread Cameron Sorlie
In a sense, you might say I did futz with mod_vmd ... to create mod_vad.
There appeared to be just no (easy) way to modify the internal VAD code in
the FreeSWITCH core (see switch_rtp.c) to identify the origins of voice
activity. And rather than build into mod_vmd, which is a special purpose
tool, a separate module for VAD seemed like a reasonable idea.

In short, the mod_vad which I've written up independently monitors the read
and the write legs of the session it is run on, and tags each VAD_TALK and
VAD_NOTALK event it fires with a user-supplied identification marker (a
short string) for the leg which the event relates to. At the moment, the VAD
algorithm is dead simple, and is much like the one in the core. I will be
happy to submit this module, in a little while, after I've had a chance to
make it perhaps a bit more useable outside of our own application context.

Cam

On Mon, Mar 2, 2009 at 5:43 PM, <
freeswitch-users-requ...@lists.freeswitch.org> wrote:

>
> On Mon, Mar 2, 2009 at 11:48 AM, Anthony Minessale
>  wrote:
> > i think that's what mod_vmd does
> >
> I think that's right. It just does the opposite - instead of looking
> for differing power levels it looks for the same power level. In other
> words it tries to detect distinctly non-human sound. I'll bet you
> could futz with that code and have it fire off events when it detects
> what it believes is human speech.
>
> -MC
>
___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Andy Spitzer
Woof!

On Mon, 02 Mar 2009 19:32:53 -0500, Steve Underwood  wrote:

 I just had a look through that patent. Its amazing. There is a lot of
> focussed descriptive text, but a patent only really consists of its
> claims. Those claims are astonishingly open-ended, and characterise what
> people had been doing for many years before it was filed - "Well we, er,
> make a call, we listen for some beeping, and we may hang up based on
> that". That is a really sick patent.

Yep, I agree.  It was the ferping lawyers who kept "adding value" to try to 
broaden it.  What we (the inventors) wrote up was nice and clean.  It does have 
some new and novel technical approaches that we really did come up with...and 
could find no prior art for.  Then the lawyers got to it.  A true example of 
what's wrong with software patents these days.

--Woof!

___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Steve Underwood
Andy Spitzer wrote:
> Woof!
>
> On Sun, 01 Mar 2009 21:28:18 -0500, Brian West  wrote:
>
>   
>> NO.  You want something that people THINK exists and works well...
>> Reliable human/voice detection doesn't exist in ANY form.
>> 
>
> I beg to differ.  See http://www.freepatentsonline.com/5521967.html for one 
> way to do it.  It works rather well and can quickly descriminate between 
> voice and tone.  I've no idea who owns that patent now (not me, for sure).
>   
I just had a look through that patent. Its amazing. There is a lot of 
focussed descriptive text, but a patent only really consists of its 
claims. Those claims are astonishingly open-ended, and characterise what 
people had been doing for many years before it was filed - "Well we, er, 
make a call, we listen for some beeping, and we may hang up based on 
that". That is a really sick patent.

Steve


___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Steve Underwood
Hi,

mod_vmd is a bit more sophisticated than that. It looks for the signal 
being narrowband energy. However, mod_vmd isn't very reliable, as it 
takes a rather high SNR for its narrowband detector to work. So high 
that a lossy codec like G.711 can barely manage it.

Regards,
Steve

Anthony Minessale wrote:
> i think that's what mod_vmd does
>
> On Mon, Mar 2, 2009 at 11:16 AM, Andy Spitzer  > wrote:
>
> Woof!
>
> On Sun, 01 Mar 2009 21:28:18 -0500, Brian West
> mailto:br...@freeswitch.org>> wrote:
>
> > NO.  You want something that people THINK exists and works well...
> > Reliable human/voice detection doesn't exist in ANY form.
>
> I beg to differ.  See
> http://www.freepatentsonline.com/5521967.html for one way to do
> it.  It works rather well and can quickly descriminate between
> voice and tone.  I've no idea who owns that patent now (not me,
> for sure).
>
> There is a simpler, less reliable way of differentiating voice
> from tone, that as far as I know isn't patented.  If you compare
> the RMS power levels of sequential 40 mS periods, call progress
> tones will have very consistent power levels from sample to
> sample.  So if 5 or more 40 mS periods have about the same power
> measurement (within say, 2%), it's a tone.  Voice will have
> dramatic power level differences over that same period.  This
> works very well in today's telephony environment, where tones are
> computer generated.  In the old days when ringback tone was
> generated off the audio hum from the 20 Hz ring voltage
> generator...not so well.
>
> --Woof!
>
> ___
> Freeswitch-users mailing list
> Freeswitch-users@lists.freeswitch.org
> 
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>


___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Steve Underwood
Andy Spitzer wrote:
> Woof!
>
> On Sun, 01 Mar 2009 21:28:18 -0500, Brian West  wrote:
>
>   
>> NO.  You want something that people THINK exists and works well...
>> Reliable human/voice detection doesn't exist in ANY form.
>> 
>
> I beg to differ.  See http://www.freepatentsonline.com/5521967.html for one 
> way to do it.  It works rather well and can quickly descriminate between 
> voice and tone.  I've no idea who owns that patent now (not me, for sure).
>   
Since when did a patent mean a problem is solved? For things like speech 
recognition you can achieve pretty high accuracy in voice detection, but 
in that case you can delay the audio and make decisions that span the 
start of the speech burst. For most telephony purposes you need to make 
a decision on the very first frame of speech, as you can't afford to add 
latency. That turns it into a tough problem. Something like the VAD in 
G.729 is about the best people can currently do, but its far from perfect.
> There is a simpler, less reliable way of differentiating voice from tone, 
> that as far as I know isn't patented.  If you compare the RMS power levels of 
> sequential 40 mS periods, call progress tones will have very consistent power 
> levels from sample to sample.  So if 5 or more 40 mS periods have about the 
> same power measurement (within say, 2%), it's a tone.  Voice will have 
> dramatic power level differences over that same period.  This works very well 
> in today's telephony environment, where tones are computer generated.  In the 
> old days when ringback tone was generated off the audio hum from the 20 Hz 
> ring voltage generator...not so well.
>   
That is *not* VAD. What you describe just says "is its energy steady". I 
will trigger on music, background noise and maybe even some of the fast 
pulsed tone signals. A proper VAD won't.

Regards,
Steve


___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Michael Collins
On Mon, Mar 2, 2009 at 11:48 AM, Anthony Minessale
 wrote:
> i think that's what mod_vmd does
>
I think that's right. It just does the opposite - instead of looking
for differing power levels it looks for the same power level. In other
words it tries to detect distinctly non-human sound. I'll bet you
could futz with that code and have it fire off events when it detects
what it believes is human speech.

-MC

___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Anthony Minessale
i think that's what mod_vmd does

On Mon, Mar 2, 2009 at 11:16 AM, Andy Spitzer  wrote:

> Woof!
>
> On Sun, 01 Mar 2009 21:28:18 -0500, Brian West 
> wrote:
>
> > NO.  You want something that people THINK exists and works well...
> > Reliable human/voice detection doesn't exist in ANY form.
>
> I beg to differ.  See http://www.freepatentsonline.com/5521967.html for
> one way to do it.  It works rather well and can quickly descriminate between
> voice and tone.  I've no idea who owns that patent now (not me, for sure).
>
> There is a simpler, less reliable way of differentiating voice from tone,
> that as far as I know isn't patented.  If you compare the RMS power levels
> of sequential 40 mS periods, call progress tones will have very consistent
> power levels from sample to sample.  So if 5 or more 40 mS periods have
> about the same power measurement (within say, 2%), it's a tone.  Voice will
> have dramatic power level differences over that same period.  This works
> very well in today's telephony environment, where tones are computer
> generated.  In the old days when ringback tone was generated off the audio
> hum from the 20 Hz ring voltage generator...not so well.
>
> --Woof!
>
> ___
> Freeswitch-users mailing list
> Freeswitch-users@lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>



-- 
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/

AIM: anthm
MSN:anthony_miness...@hotmail.com 
GTALK/JABBER/PAYPAL:anthony.miness...@gmail.com
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:8...@conference.freeswitch.org 
iax:gu...@conference.freeswitch.org/888
googletalk:conf+...@conference.freeswitch.org
pstn:213-799-1400
___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-02 Thread Andy Spitzer
Woof!

On Sun, 01 Mar 2009 21:28:18 -0500, Brian West  wrote:

> NO.  You want something that people THINK exists and works well...
> Reliable human/voice detection doesn't exist in ANY form.

I beg to differ.  See http://www.freepatentsonline.com/5521967.html for one way 
to do it.  It works rather well and can quickly descriminate between voice and 
tone.  I've no idea who owns that patent now (not me, for sure).

There is a simpler, less reliable way of differentiating voice from tone, that 
as far as I know isn't patented.  If you compare the RMS power levels of 
sequential 40 mS periods, call progress tones will have very consistent power 
levels from sample to sample.  So if 5 or more 40 mS periods have about the 
same power measurement (within say, 2%), it's a tone.  Voice will have dramatic 
power level differences over that same period.  This works very well in today's 
telephony environment, where tones are computer generated.  In the old days 
when ringback tone was generated off the audio hum from the 20 Hz ring voltage 
generator...not so well.

--Woof!

___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Henry Huang
ignore_early_media=true is not going to do the trick since once the IVR
picks up the call on leg A, the ring tone is stopped and the IVR is going to
play pre-recorded voice menu. And the freeswtich is going to send DTMF to
reach a certain extension number say 101. Then the ring tone is going to
start again while the IVR is going to dial the 101 extension(or even play
moh while dialing). After extension 101 picks up, this is when I want the
"originate" to connect call leg B on some other number.

On Sun, Mar 1, 2009 at 7:11 PM, Brian West  wrote:

> Usually ringing is done in early media... so the best bet would be to
> ignore_early_media=true
> /b
>
> On Mar 1, 2009, at 9:05 PM, Henry Huang wrote:
>
> Well, I knew it would be some future fantasy for now..
> If not human detection. I guess will try to use Dialplan Tools wait for
> silence to wait till the ring tone is finished ,then connect the other leg.
>
>
>
> ___
> Freeswitch-users mailing list
> Freeswitch-users@lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>


-- 
Henry Huang
UniC Solution - Communication Unified
VoIP & Open Source software Consultant
___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Brian West
Usually ringing is done in early media... so the best bet would be to  
ignore_early_media=true


/b

On Mar 1, 2009, at 9:05 PM, Henry Huang wrote:


Well, I knew it would be some future fantasy for now..
If not human detection. I guess will try to use Dialplan Tools wait  
for silence to wait till the ring tone is finished ,then connect the  
other leg.




___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Henry Huang
Well, I knew it would be some future fantasy for now..
If not human detection. I guess will try to use Dialplan Tools wait for
silence to wait till the ring tone is finished ,then connect the other leg.






On Sun, Mar 1, 2009 at 6:28 PM, Brian West  wrote:

> NO.  You want something that people THINK exists and works well...
> Reliable human/voice detection doesn't exist in ANY form.
>
> /b
>
> On Mar 1, 2009, at 8:20 PM, Henry Huang wrote:
>
> > Does the freeswitch VAD is able to distinguish ring tone from human
> > voice?
> > The scenario is to originate a call to a IVR system(don't connect
> > the other leg here yet) and dial DTMF to get to the designated
> > extension number , once someone picks up and say hello ( detected by
> > VAD) now release to connect the other leg of the call. The point is
> > to hold the first leg till a real person picks up.
> >
> > If it can't be done by VAD, how should I approach this function that
> > I want to achieve.
> >
> > Thanks
>
>
> ___
> Freeswitch-users mailing list
> Freeswitch-users@lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>



-- 
Henry Huang
UniC Solution - Communication Unified
VoIP & Open Source software Consultant
___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Brian West
NO.  You want something that people THINK exists and works well...  
Reliable human/voice detection doesn't exist in ANY form.

/b

On Mar 1, 2009, at 8:20 PM, Henry Huang wrote:

> Does the freeswitch VAD is able to distinguish ring tone from human  
> voice?
> The scenario is to originate a call to a IVR system(don't connect  
> the other leg here yet) and dial DTMF to get to the designated  
> extension number , once someone picks up and say hello ( detected by  
> VAD) now release to connect the other leg of the call. The point is  
> to hold the first leg till a real person picks up.
>
> If it can't be done by VAD, how should I approach this function that  
> I want to achieve.
>
> Thanks


___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Henry Huang
Does the freeswitch VAD is able to distinguish ring tone from human voice?
The scenario is to originate a call to a IVR system(don't connect the other
leg here yet) and dial DTMF to get to the designated extension number , once
someone picks up and say hello ( detected by VAD) now release to connect the
other leg of the call. The point is to hold the first leg till a real person
picks up.

If it can't be done by VAD, how should I approach this function that I want
to achieve.

Thanks

On Sun, Mar 1, 2009 at 1:15 PM, Brian West  wrote:

> If i'm not mistaken those events will have a member-id in them so you
> can tell who they belong to.
>
> /b
>
> On Mar 1, 2009, at 12:01 PM, Cameron Sorlie wrote:
>
> > Using voice activity detection (VAD) in FreeSWITCH, how might I then
> > distinguish which side of a call any given TALK or NOTALK event
> > relates to? I am interested not just that there is activity on the
> > call, but interested also in which party on the call is speaking (or
> > not).
> >
> > Cam
>
>
> ___
> Freeswitch-users mailing list
> Freeswitch-users@lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>



-- 
Henry Huang
UniC Solution - Communication Unified
VoIP & Open Source software Consultant
___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


Re: [Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Brian West
If i'm not mistaken those events will have a member-id in them so you  
can tell who they belong to.

/b

On Mar 1, 2009, at 12:01 PM, Cameron Sorlie wrote:

> Using voice activity detection (VAD) in FreeSWITCH, how might I then  
> distinguish which side of a call any given TALK or NOTALK event  
> relates to? I am interested not just that there is activity on the  
> call, but interested also in which party on the call is speaking (or  
> not).
>
> Cam


___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


[Freeswitch-users] Detecting the origin of voice activity using VAD

2009-03-01 Thread Cameron Sorlie




Using voice activity detection (VAD) in FreeSWITCH, how might I then
distinguish which side of a call any given TALK or NOTALK event relates
to? I am interested not just that there is activity on the call, but
interested also in which party on the call is speaking (or not).

Cam




  
  
  
  

  
  
  
  
  
  
  
  


  
  
  
  
  
  
  
  


  
  
  
  
  
  
  
  


  
  
  
  
  
  
  
  


  
  
  
  
  
  
  
  

  







___
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org