Menu

n-best hypothesis out of grammar

Help
z x
2011-05-19
2012-09-22
  • z x

    z x - 2011-05-19

    Hi,

    I got out-of-grammar hypothesis in n-best lists. I'm wondering if it's normal.

    Here is all the file needed. It's in chinese, but quite simple.
    https://rapidshare.com/files/2150225830/file.rar

    Thanks

     
  • Nickolay V. Shmyrev

    Sorry, can you please describe your problem in more details? I'm not sure I
    understand it.

     
  • z x

    z x - 2011-05-20

    Sorry, my fault. I tried to obtain n-best lists with jsgf of some raw file I
    recorded with pocketsphinx_batch. But to my surprise, one of the n-best lists
    contains so many out-of-grammar hypothesis. I'm wondering if it's normal. The
    raw file, dic file, jsgf file and acoustic model are contained in the file
    above.

     
  • Nickolay V. Shmyrev

    By out-of-grammar you mean that words are not in order? You need to add
    -fwdflat no then.

     
  • z x

    z x - 2011-05-20

    No, that's no what I mean. Let me take an example. I have a jsgf file like
    this:

    <name> = (A|B|C); </name>

    So A or B X are valid hypothesis. But sometimes I got A B or A X X in n-best
    outputs. What should we call it?

     
  • Nickolay V. Shmyrev

    As I told you need "-fwdflat no"

     
  • z x

    z x - 2011-05-20

    Thanks for your quick reply. But with -fwdflat no the n-best is still the
    same. Is there anything else I have to set?

     
  • z x

    z x - 2011-05-21

    What's more, such error may occur with -nbest and -nbestdir

    *** glibc detected *** pocketsphinx_batch: free(): invalid pointer: 0x09eb97f0 ***
    ======= Backtrace: =========
    /lib/libc.so.6(+0x6c501)
    /lib/libc.so.6(+0x6dd70)
    /lib/libc.so.6(cfree+0x6d)
    /usr/local/lib/libsphinxbase.so.1(ckd_free+0x21)
    /usr/local/lib/libpocketsphinx.so.1(ps_astar_finish+0x2a)
    /usr/local/lib/libpocketsphinx.so.1(ps_nbest_free+0x1d)
    /usr/local/lib/libpocketsphinx.so.1(ps_nbest_next+0x3c)
    pocketsphinx_batch
    pocketsphinx_batch
    pocketsphinx_batch
    /lib/libc.so.6(__libc_start_main+0xe7)
    pocketsphinx_batch
    ======= Memory map: ========
    00110000-0014c000 r-xp 00000000 08:01 394852
    /usr/local/lib/libpocketsphinx.so.1.1.0
    0014c000-0014d000 r--p 0003c000 08:01 394852
    /usr/local/lib/libpocketsphinx.so.1.1.0
    0014d000-0014e000 rw-p 0003d000 08:01 394852
    /usr/local/lib/libpocketsphinx.so.1.1.0
    0014e000-00163000 r-xp 00000000 08:01 274697 /lib/libpthread-2.12.1.so
    00163000-00164000 ---p 00015000 08:01 274697 /lib/libpthread-2.12.1.so
    00164000-00165000 r--p 00015000 08:01 274697 /lib/libpthread-2.12.1.so
    00165000-00166000 rw-p 00016000 08:01 274697 /lib/libpthread-2.12.1.so
    00166000-00168000 rw-p 00000000 00:00 0
    001e2000-001e9000 r-xp 00000000 08:01 274699 /lib/librt-2.12.1.so
    001e9000-001ea000 r--p 00006000 08:01 274699 /lib/librt-2.12.1.so
    001ea000-001eb000 rw-p 00007000 08:01 274699 /lib/librt-2.12.1.so
    00217000-0036e000 r-xp 00000000 08:01 274683 /lib/libc-2.12.1.so
    0036e000-00370000 r--p 00157000 08:01 274683 /lib/libc-2.12.1.so
    00370000-00371000 rw-p 00159000 08:01 274683 /lib/libc-2.12.1.so
    00371000-00374000 rw-p 00000000 00:00 0
    00374000-00434000 r-xp 00000000 08:01 395810 /usr/lib/libasound.so.2.0.0
    00434000-00435000 ---p 000c0000 08:01 395810 /usr/lib/libasound.so.2.0.0
    00435000-00439000 r--p 000c0000 08:01 395810 /usr/lib/libasound.so.2.0.0
    00439000-0043a000 rw-p 000c4000 08:01 395810 /usr/lib/libasound.so.2.0.0
    0067c000-006a0000 r-xp 00000000 08:01 274687 /lib/libm-2.12.1.so
    006a0000-006a1000 r--p 00023000 08:01 274687 /lib/libm-2.12.1.so
    006a1000-006a2000 rw-p 00024000 08:01 274687 /lib/libm-2.12.1.so
    0089f000-008a1000 r-xp 00000000 08:01 274686 /lib/libdl-2.12.1.so
    008a1000-008a2000 r--p 00001000 08:01 274686 /lib/libdl-2.12.1.so
    008a2000-008a3000 rw-p 00002000 08:01 274686 /lib/libdl-2.12.1.so
    00b3e000-00b5a000 r-xp 00000000 08:01 274680 /lib/ld-2.12.1.so
    00b5a000-00b5b000 r--p 0001b000 08:01 274680 /lib/ld-2.12.1.so
    00b5b000-00b5c000 rw-p 0001c000 08:01 274680 /lib/ld-2.12.1.so
    00c2d000-00c47000 r-xp 00000000 08:01 264754 /lib/libgcc_s.so.1
    00c47000-00c48000 r--p 00019000 08:01 264754 /lib/libgcc_s.so.1
    00c48000-00c49000 rw-p 0001a000 08:01 264754 /lib/libgcc_s.so.1
    00c6e000-00c6f000 r-xp 00000000 00:00 0
    00f1f000-00f60000 r-xp 00000000 08:01 406947
    /usr/local/lib/libsphinxbase.so.1.1.1
    00f60000-00f61000 r--p 00040000 08:01 406947
    /usr/local/lib/libsphinxbase.so.1.1.1
    00f61000-00f62000 rw-p 00041000 08:01 406947
    /usr/local/lib/libsphinxbase.so.1.1.1
    00f62000-00f63000 rw-p 00000000 00:00 0
    08048000-0804f000 r-xp 00000000 08:01 406929 /usr/local/bin/pocketsphinx_batch
    0804f000-08050000 r--p 00006000 08:01 406929 /usr/local/bin/pocketsphinx_batch
    08050000-08051000 rw-p 00007000 08:01 406929 /usr/local/bin/pocketsphinx_batch
    09c6f000-09f23000 rw-p 00000000 00:00 0
    b5409000-b603f000 rw-p 00000000 00:00 0
    b6b00000-b6b21000 rw-p 00000000 00:00 0
    b6b21000-b6c00000 ---p 00000000 00:00 0
    b6c50000-b78df000 rw-p 00000000 00:00 0
    b78ee000-b78f0000 rw-p 00000000 00:00 0
    bf827000-bf848000 rw-p 00000000 00:00 0
    Aborted

     
  • Nickolay V. Shmyrev

    Hello

    I fixed the segmentation fault, please update. But I can't reproduce your
    order issue. Maybe you can provide the sample I can run, for now I don't see
    the acoustic model in your archive.

     
  • z x

    z x - 2011-05-22

    Thanks for your work. But a new seg fault occured. Here's the stacktrace:

    Program received signal SIGSEGV, Segmentation fault.
    ps_astar_next (nbest=0x0) at ps_lattice.c:1734
    1734 dag = nbest->dag;

    Thread 1 (Thread 0xb7fec6c0 (LWP 11601)):

    0 ps_astar_next (nbest=0x0) at ps_lattice.c:1734

    1 0x00162412 in ps_nbest_next (nbest=0x0) at pocketsphinx.c:994

    2 0x08049ccc in write_nbest (ps=<value optimized="" out="">,</value>

    nbestdir=<value optimized="" out="">, uttid=<value optimized="" out="">) at batch.c:494 </value></value>

    3 0x0804a95c in process_ctl (ps=<value optimized="" out="">,</value>

    config=<value optimized="" out="">, ctlfh=<value optimized="" out="">) at batch.c:759 </value></value>

    4 0x0804b280 in main (argc=13, argv=0xbffff304) at batch.c:824

    All the files needed are here,
    https://rapidshare.com/files/3741627632/file.rar

    000000002.raw may lead to the order issue, and 000000020.raw may lead to the
    seg fault.

     
  • Nickolay V. Shmyrev

    Hello

    Those bugs were just fixed in trunk. Please update, everything should be fine
    now including the n-best.

     

Log in to post a comment.