Comments

Flat
Number as label
User: Manuel
Date: 9/3/2007 11:30 am
Views: 4587
Rating: 31

When you execute: 

$HLEd -A -D -T 1 -l '*' -d dict -i phones0.mlf mkphones0.led words.mlf

if you have some number in the word of the file words.mlf this are not recognize as label, for example if I have :

"*/sample1"

1

+

3

HLEd not work, it's ok the follow:

"*/sample1"

ONE

+

THREE

How can I resolve this?

Tks 

Re: Number as label
User: kmaclean
Date: 9/3/2007 12:05 pm
Views: 264
Rating: 27

Hi Manuel,

The tutorial lexicon does not use "numeric" numbers (i.e. 1,2,3,4, 10, 100, ...).  It uses "alpha" numbers (i.e. one, two, three, four, ten, one hundred, ...). The easy to address this is to just use alpha numbers in your grammar. 

If you really want numeric numbers in your grammar, you need to add them into your pronunciation dictionary (also called a lexicon).  In Step 2, you downloaded the voxforge_lexicon.  You need to add the pronunciation for the numeric numbers into the lexicon:

1        w ah n
2        t uw
3        th r iy
4        f ow r
5        f ay v
6        s ih k s
7        s eh v ih n
8        ey t
9        n ay n
0       z iy r ow
0(2)        ow 

I am not sure if these entries should go at the beginning of your lexicon file or at the end - try it out and see which works.

Then recreate your pronunciation dictionary (dict) as set out in Step 2 (you could also just add these entries directly to you dict file, but these would get overwritten next time you go through Step 2).

Ken

 

 



Re: Number as label
User: Manuel
Date: 9/6/2007 8:23 am
Views: 255
Rating: 27

I've modified lexicon file, but it doesn't work, it give me the same error.

I want number and not alpha, so when it recognize a number, it write out a "number", not the respective word.

Tks

Manuel 

Re: Number as label
User: kmaclean
Date: 9/6/2007 10:52 am
Views: 266
Rating: 26

Hi Manuel: 

Did you remove the “alpha” numbers (i.e. One, two, three ...) from the lexicon? It may be that when the speech recognition engine recognizes a series of phones, it returns the first word in the lexicon matching the sequence of phones. Since “one” and “1” have the same phonemes, then the Speech Recognition engine returns “one”, since it comes before “1” alphabetically.

Did you modify you grammar file to have “numeric” numbers? like this:

% NS_B
<s>        sil

% NS_E
</s>        sil

% CALL_V
PHONE        f ow n
CALL        k ao l

% DIAL_V
DIAL        d ay l

% NAME_N
STEVE        s t iy v
YOUNG        y ah ng

% DIGIT
5        f ay v
4        f ow r
9        n ay n
8        ey t
1        w ah n
7        s eh v ih n
6        s ih k s
3        th r iy
2        t uw
0      z iy r ow

 

Another approach would be to modify just the return values (i.e. the text in brackets: “[“, “]”) of the alpha number in your lexicon file (rather than adding new entries for “numeric” numbers), like this :

one [1]        w ah n
two [2]        t uw
three [3]        th r iy
four [4]        f ow r
five [5]        f ay v
six [6]        s ih k s
seven [7]        s eh v ih n
eight [8]        ey t
nine [9]        n ay n
zero [0]       z iy r ow
zero(2) [0]       ow

You would still need to modify your grammr file to use numbers.

Hope these suggestions help!

Ken 

 

Previous