festvox / festival

Festival Speech Synthesis System
Other
386 stars 58 forks source link

Segmentation fault with dumpfeats #6

Closed gillesdegottex closed 6 years ago

gillesdegottex commented 6 years ago

Hi,

Using master version of festival, I get a Seg fault when running: festival/examples/dumpfeats -eval extra_feats.scm -relation Segment -feats label.feats -output tmp arctic_a0062.txt

extra_feats.scm and label.feats from: https://github.com/CSTR-Edinburgh/merlin/tree/master/misc/scripts/frontend/festival_utt_to_lab/

and input file: (had to rename it to .txt bcs of GitHub limitations, it is a .utt) arctic_a0062.txt

gillesdegottex commented 6 years ago

The sentence is "The dog's bone". Note that if the quote is removed, the Seg fault does not happen.

saikrishnarallabandi commented 6 years ago

Hi,

I notice that the quotes are appropriately formatted. So probably they are not the issue. I was able to dump the features without removing the quotes. At first glance, the feats look ok-ish. (attached). Do they seem reasonable?

arctic_a0062.txt

gillesdegottex commented 6 years ago

Hi, thanks for the quick response.

I don't know how the resulting file should look like, I just know it is supposed to be processed flawlessly.

Can you tell me what OS/distribution/GCC you're using? Mine: Ubuntu-17.10 GCC=gcc (Ubuntu 6.4.0-8ubuntu1) 6.4.0 20171010

And I followed Festival's installation from here: https://github.com/CSTR-Edinburgh/merlin/blob/master/tools/compile_other_speech_tools.sh

Do you see any issue here ?

gillesdegottex commented 6 years ago

Using festival 2.4, I got the error: "SIOD ERROR: unbound variable : eof"

festvox commented 6 years ago

Hmm, works for me too (with 2.5) which means there is something different in our environments, I can't think of anything that changed here between 2.4 and 2.5

Can you tell me which you have $LANG set to (at the shell) echo $LANG

what happens if you set this to "C"

export LANG=C

Second Festival can give us a little more information about where it gets its error. Create or edit ~/.festivalrc and add the line

(set_backtrace t)

Then run the dumpfeats command and post the error you get

gillesdegottex commented 6 years ago

echo $LANG

en_GB.UTF-8

Still crashes after "export LANG=C"

It crashes without output after adding the ~/.festivalrc

No output either with 2.4

gillesdegottex commented 6 years ago

What is the GCC version you're using for compiling speech_tools,festival, etc. ?

gillesdegottex commented 6 years ago

It worked using gcc-4.8

festvox commented 6 years ago

Yes that's it, if you want to use gcc 6+ you need to use festival 2.5 (from this repository) rather than 2.4

gillesdegottex commented 6 years ago

I was trying with festival 2.5. Only gcc-4.8 succeeded to make me a stable version. Above, I was just saying that the crashes happened similarly between 2.4 and 2.5.

Out of curiosity, what is so badly un-portable from one gcc version to another in festival ?

festvox commented 6 years ago

2.5 is tested on all updated versions of gcc (I believe) so that should work.

Festival/Speech tools were written 25 year ago when C++ was even less stable, and realistically C++ isn't really a stable language. speech_tools used to be a compile bench mark for gcc 15 years ago so they tested on our system before they released gcc but that's too hard now. Even when you make your code C++ compliant, you can't guarantee it'll still be compliant with the next compiler release.

gillesdegottex commented 6 years ago

2.5 is tested on all updated versions of gcc

You might want to run some tests on Travis CI for that, that could also help you to follow uncompatibilities.

priyanthini commented 4 years ago

I'm using gcc 7.5.0 (Ubuntu 18.04) and festival 2.5 but I'm getting this error. I tried with both festival 2.4 and 2.5 but that error is till there as : " SIOD ERROR: unbound variable : eof gawk: fatal: cannot open file ./test/labels//tmp' for reading (No such file or directory) gawk: fatal: cannot open file ./test/labels//tmp' for reading (No such file or directory) "

Can someone help me with this issue?

seblemaguer commented 3 years ago

FYI, valgrind indicates this stacktrace:

==34== Invalid read of size 8                                                                                                                                            
==34==    at 0x280108: EST_Item::length() const (EST_Item.cc:235)                                                                                                        
==34==    by 0x18F667: ff_syl_numphones(EST_Item*) (ff.cc:335)                                                                                                           
==34==    by 0x18F71C: ff_word_numsyls(EST_Item*) (EST_Item_Content.h:107)                                                             
==34==    by 0x126866: ffeature(EST_Item*, EST_String const&) (features.cc:275)       
==34==    by 0x127B4B: lisp_item_feature(obj*, obj*) (features.cc:300)                              
==34==    by 0x1F3F49: leval(obj*, obj*) (slib.cc:1450)                                                     
==34==    by 0x1F5735: l_unwind_protect(obj*, obj*) (slib_core.cc:262)                                                                                                   
==34==    by 0x1F3E00: leval(obj*, obj*) (slib.cc:1474)                                                                                                                  
==34==    by 0x1F5AF1: leval_setq(obj*, obj*) (slib_core.cc:26)                   
==34==    by 0x1F3E00: leval(obj*, obj*) (slib.cc:1474)                                        
==34==    by 0x1F5C6C: leval_progn(obj**, obj**) (slib_core.cc:91)                    
==34==    by 0x1F3DD8: leval(obj*, obj*) (slib.cc:1478)                                             
==34==  Address 0x10 is not stack'd, malloc'd or (recently) free'd  

GCC information is the following:

COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/7/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 7.5.0-3ubuntu1~18.04' --with-bugurl=file:///usr/share/doc/gcc-7/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=/usr --with-gcc-major-version-only --program-suffix=-7 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04) 
seblemaguer commented 3 years ago

It fails when the apostrophe is a possessive forms (Peter's, ...) on my side.

ddavout commented 3 years ago

I used to have this problem with festival/examples/dumpfeat. Right now, I am developing a voice that don't use apostrophe as a whitespace contrarily to the CMU one's but what I can tell is that I encountered a problem with temporary files somewhere else and that it disappeared when I followed the advice of festival-freebsoft-utils in its utils.scm they say

;; There is a bug in speech-tools preventing it to honor $TMPDIR. ;; We can work around the bug by setting some other environment variables. and they use

(let ((tempdir (getenv "TMPDIR")))
(when (and tempdir (not (equal? tempdir "")))
(setenv "TEMP" tempdir)
(setenv "TMP" tempdir)))