# Festival tips:  more understandable and books to audiobooks

## fireboy1919

If you're reading this, you probably know what Festival is - it's a text to speech engine that produces choppy speech from text.

Well, it's been given a major improvement in the form of a hidden Markov Model based synthesis engine.

http://hts.ics.nitech.ac.jp/

These things sound WAY better.

To install:  

After installing festival, download and unzip one of the festival engines.

http://hts.ics.nitech.ac.jp/download.html

It's going to create a directory structure that's different than the one currently used by festival, so you have to copy it out to the right spot.

At the time of this writing, english Festival voices are stored in:

/usr/lib/festival/voices/english

by default.  Untar and copy the code in lib/voices/us there:

I prefer the "slt" voice.

```

tar xzvf cmu_us_slt_arctic_hts.tar.gz

cp -r lib/voices/us/* /usr/lib/festival/voices/english

```

Making this the default voice:

Unfortunately there's something wrong with these engines, and I didn't want to read all the way through all of Festival to figure it out.  Suffice to say it's something in the initialization.  You'll have to start with some other voice before loading any of these.  

For that reason, make this your /usr/lib/festival/siteinit.scm (with suitable modification based on whichever voice you downloaded) file:

```
(voice_kal_diphone)

(set! voice_default 'voice_cmu_us_slt_arctic_hts)
```

Troubleshooting

1) You have to have perl on your system, because the interface between Festival and this voice is written in perl.  Make sure you have perl installed.

2) The actual engine, which is stored at 

/usr/lib/festival/voices/english/[whatever you installed]/hts_engine

is an ELF x86 binary.  If you don't have that, you'll have to recompile and copy it in there.  It's available in the download section from the website I mentioned.

Making audio books

The result is, in fact, so legible that I'd use it to listen to books-on-mp3.

You can get plenty of books from the Gutenberg archive worth listening to for those long drives.

The problem, though, is that festival's text2wave engine tries to keep everything in memory, and I just don't have 10GB of memory to spare.

So...here's a bit of perl to do it in chunks (Yeah, I could have used bash, as the hack I wrote is almost a shell script, but I like perl, okay?  Live with it.).  It uses lame, and joins the files together in the traditional method with mp3s: using cat.

```
#!/usr/bin/perl 

open(FILE1,$ARGV[0]);

my ($parnumber,$f)=(0,0);

my $paragraph=50;

while($f=<FILE1>)

{

 for(my $i=0; $i<$paragraph; $i++)

 { last if(!($f .=<FILE1>)); };

 print $parnumber . "\n";

 my $filename=sprintf("temp%05d",$parnumber);

 open(TEXTIN,"|text2wave -F 44100 -o $filename.wav");

 print TEXTIN $f;

 close(TEXTIN);

 system("lame $filename.wav $filename.mp3");

 $parnumber++;

 system("touch $ARGV[1] && cat $filename.mp3 >> $ARGV[1] && rm $filename.*");

};

```

There's one tweakable value:  the variable paragraph.  It specifies how many lines to send to text2wave at a time.  More means you need more temp space, but then again, there's less overhead from stopping and restarting the program.

Just give it the input plain text filename, and the output mp3 name, and wait.  If it's a good-sized novel, you'll be waiting quite some time.

Edit:

Thanks for the catch there, ootneg.  I missed that last } when I copied the file to here.  There's something else you might use.  

A lot of books you get have built-in word wraps.  This sounds really bad when it happens in the middle of the word.  Well, with the help of perl and ispell, you can get rid of those pesky word wraps.  Because I use this so that I can put books on my PDA and have the line wrap look right, it will actually wrap anytime there isn't two "\n" in a row following a period (or a period then a quote mark).

```
#!/usr/bin/perl

use Lingua::Ispell qw(spellcheck);

#Lingua::Ispell::allow_compounds(1);

my ($line,$line2,$output);

open(FILE,$ARGV[0]);

$endword,$currline;

while(!($endword eq "eof13432"))

{

 ($currline,$endword)=addline($endword);

 print $currline;

}

close(FILE);

sub addline

{

 my $endword=shift;

 my @word;

 chomp($endword);

 my $line;

 return ($endword . "\n","eof13432") if(!($line=<FILE>));

 return ($endword ,"") if($line=~/^\s*$/ && (!($endword=~/(.*)\.\"?$/)));

 return ($endword . "\n\n","") if($line=~/^\s*$/);

 $line=~/^\s*([^\s]+)(.*?)([^\s]+)?\s*$/;

 my ($beginword,$middle,$end)=($1,$2,$3);

 if($endword=~/(.*)\-$/)

 {

  $endword=$1;

  my $maybe=$endword.$beginword;

  @word=@{spellcheck($maybe)};

  return ($maybe . $middle, $end)  if(!spellcheck($maybe));

 }

 return ($endword . " " . $beginword . $middle,$end) if(length($endword)>0);

 return ($beginword . $middle , $end);

}

```

To use this piece of code, you have to have Lingua::Ispell installed, as well as ispell (it combines words if it notices that theres a "-" at the end of a line and the combination forms a word in the ispell dictionary).

Check if you have ispell with emerge (emerge -s ispell).  Check if you have Lingua::Ispell by using CPAN.  To do this, type

```
perl -MCPAN -e shell
```

as root, and then (after configuring it if you haven't done it before), type 

```
install Lingua::Ispell
```

at the cpan prompt.  Typing exit will exit the CPAN shell.Last edited by fireboy1919 on Wed Jul 21, 2004 3:36 am; edited 2 times in total

----------

## ootneg

 *fireboy1919 wrote:*   

> http://hts.ics.nitech.ac.jp/

 

 *fireboy1919 wrote:*   

> http://hts.ics.nitech.ac.jp/download.html

 

Unfortunately, both of these links timeout when I try to load them

 *Epiphany-1.2.2 wrote:*   

> Proxy Error
> 
> The proxy server received an invalid response from an upstream server.
> 
> The proxy server could not handle the request GET http://hts.ics.nitech.ac.jp/.
> ...

 

Is the site unreliable, or did it disappear just hours after the original post?

----------

## floam

Me too. Times out.

----------

## fireboy1919

I don't know what that's all about.  

I don't own the site or control it.  You might notice it's in Japan?  

Perhaps there's some kind of blockage there.

I just did this, right before posting.  I have no idea why it would be down so suddenly.

Edit

As you wish, I've uploaded the best of the voices to my site, as their license for use is incredibly liberal.

I'm low on bandwidth, and running dialup, so you'll have to wait for Japan's servers to come back up to get the rest.

http://rustyp.freeshell.org/gentoo/cmu_us_slt_arctic_hts.tar.bz2

By the way, have you tried messing with Festival?  There are a lot better voices than the default one.  I like the English guy best of the defaults, whichever one that was.  You can see available voices (and the path) by typing

(list voice-locations)

Edit2

For a limited time, also available from me is HTS-1.1.1 for HTK, which is the engine that actually makes the words.  You won't need this unless you can't use x86 ELF binaries.

http://rustyp.freeshell.org/gentoo/HTS-1.1.1_for_HTK-3.2.1.tar.gzLast edited by fireboy1919 on Sat Jul 10, 2004 10:11 am; edited 2 times in total

----------

## ootneg

Yes, I did notice that it is in Japan.  I did not expect that it was your site.  I also noticed that it had only been a few hours between your post and my attempt.  I doubt that they blocked it as a result of high traffic because of this forrum page as only 12 visitors had viewed this post before I did.

Do you still happen to have the tar.gz file?  Do you have any way to post it (if their licensing will allow)?  I'ld like to try this out.  The default voice is not even as good as the one on "War Games".

Thank you.

----------

## ootneg

I had not tried to use the other voices.  I understood that there was only one voice and that your instructions were to add new voices.  I was wrong.  I've been reading the documentation and have learned to do quite a bit with this program.  I have used all of the voiced that come with it.  I also emerged mbrola and used the three voices with that package.

Unfortunately, I have not yet gotten this to work with the voice I got from you.  When I try to use it, I get an error:

 *Quote:*   

> estival> (voice_cmu_us_slt_arctic_hts)                    
> 
> cmu_us_slt_arctic_hts
> 
> festival> (SayText "Good morning, welcome to Festival")
> ...

 

I've got a long drive tomorrow and I should be sleeping already.  I'll try getting this to work later this weekend.  Hopefully it is just something simple that I have missed.

Thank you for your instructions.  I enjoy playing with this kind of stuff.

----------

## floam

I get the same thing.

----------

## banadushi

Seems to me, by the name given in the documentation, that these are just the CMU ARCTIC from http://www.festvox.org/cmu_arctic/

[Yea so i'm an idiot, jsut ignore this post]Last edited by banadushi on Sat Jul 10, 2004 9:57 am; edited 1 time in total

----------

## fireboy1919

Perceptive.  These people used the arctic dataset to construct their model, but the synthesis engine is different.  As I said, they use a Hidden Markov Model.

Like I said, this voice uses a separate synthesis engine, called "HTS."

If you've followed my instructions, it should be

/usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts/hts_engine

There's two things I suppose I should mention (will mention above)

1)  This is a binary. Specifically, it's an ELF-x86 binary.  Source code is available in the download section, so if it doesn't work for you, you can get it there...when the site goes up.  I'll put another temp link.

2)  The interface between this binary and festival is perl, so you need perl on your system.

----------

## ootneg

I did follow the instructions and to have the engine in the same location that you indicated:

 *Quote:*   

> # ll /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts/hts_engine
> 
> -rwxr-xr-x  1 root root 1662248 Jul 10 01:21 /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts/hts_engine
> 
> # 

 

I also have perl:

 *Quote:*   

> % which perl
> 
> /usr/bin/perl
> 
> % perl -v
> ...

 

Apparently the problem is somewhere else.  I'll keep looking.

----------

## kpoman

Iam higly interested in setting this up too  :Smile: 

The site is still dead ! I guess I'll have to wait  :Embarassed: 

----------

## ootneg

I tried this again on a different system and all works well.  I followed the exact same steps and everything works.  Myabe I had a corrupted download on the other system.  I'll have to try to redoo the setup there and see if it makes a difference.

Anyway, the only thing I needed in addition to the emerged packages was the cmu_us_slt_arctic_hts.tar.bz2 package from http://hts.ics.nitech.ac.jp/ offered by fireboy1919.  I unpacked the archive and copied it acording to his instructions.  On the second computer, all worked well.

Also, the script that he gave works extreemly well after making one syntax correction.  It returned the error

 *Quote:*   

> Missing right curly or square bracket at bookscript.pl line 16, at end of line
> 
> syntax error at bookscript.pl line 16, at EOF
> 
> Execution of bookscript.pl aborted due to compilation errors.

 

To correct this, I added a curly bracket '}' just before the semicolon at the end of the last line.  This closed the while loop and then the script worked fine.

I used it with the other voices for testing.  Now that I have this voice, I will use it for the books that I have in txt format.

Thank you fireboy1919  This is a great post!

----------

## kpoman

could someone maybe post the voice somewhere so wa can download it ? it seems like the link is completely broken !

----------

## ootneg

The fourth post in this thread is by fireboy1919 and he has been good enough to post this information as a temp solution while the site is down.  Look there for the links.

I only needed the link from the first edit.  If you do not have the engine, you may need the link from edit2 in that post.  If you would like to hear samples of the different voices without the need to install them first, you may check here

http://festvox.org/voicedemos.html

Hope this helps.

----------

## iten

Hmm... I get the same problem as all the others.

A clue might be the htsvoice.pl in the same directory as hts_engine?

raven hts # ./htsvoice.pl 

awk: fatal: can't open source file `/label-full.awk' for reading (No such file or directory)

sh: line 1: /hts_engine: No such file or directory

is this the interface you were talking about?

It seems that some paths are wrong...

Actually, on closer look, no... the path is the argument.

Never mind, but does anyone have any clues?

If it helps: I have only emerged festival and speechd, no extra voices. Perhaps you need the original CMU ARCTIC?

Argh, too bad their site is down

----------

## ootneg

I couldn't find any differences between the files on the working system and the system where this voice did not work.  In my search, I decided to check for any broken library dependencies by running 'revdep-rebuild' (supplied by app-portage/gentoolkit from portage) on the non-working system..  The output included this:

 *Quote:*   

> Checking dynamic linking consistency...
> 
>   broken /usr/lib/perl5/site_perl/5.8.0/i586-linux/auto/PDL/Slatec/Slatec.so (requires libg2c.so.0)

 

It then determined that to fix the dependency, it should run:

 *Quote:*   

> emerge --oneshot --nodeps  =dev-perl/PDL-2.4.0 

 

Since we have already discussed the need for perl, I figured that a broken perl dependency may be responsible for this problem.  I let it do this emerge.  Unfortunately this did *not* fix the problem.  I also tried to remerge festival after this to see if it would make any difference.  No luck.

Based on the error message, the problem appears to be either with reading or writting to the /tmp directory.

 *Quote:*   

> festival> (voice_cmu_us_slt_arctic_hts)
> 
> cmu_us_slt_arctic_hts
> 
> festival> (SayText "help")             
> ...

 

I checked to see if the expected files were there:

 *Quote:*   

> /tmp% ll | grep est
> 
> /tmp%

 

No files in /tmp/ contain 'est' in their names.  Apparently the temp wave files are not being written as needed.  I looked at the permissions of /tmp and cannot see any reason that any application (run by any user) should have problems with writting to it

% ll / | grep tmp

drwxrwxrwt   23 root root      4256 Jul 15 21:10 tmp/

%

With these permissions, any user should be able to create his own files as though they were within his own diskspace.  The sticky bit makes it so that users cannot tamper with other user's files, but I see no conflict with the file names.

It seams that I am looking in the right direction, but I don't know what is causing this behavior.

If anybody learns more, I'ld like to understand what is happening.

----------

## iten

Mine has no problems writing to the tmp directory, because I was fast enough to catch the directory it creates before festival deletes it.

The contents it seems to create (before deleting it) are:

joel@raven joel $ ls /tmp/est_2*

tmp.f0  tmp.lab  tmp.mcep  tmp.raw  utt.feats

Sorry I couldn't get the permissions.

The file it tries to load is /tmp/(number-- looks like the PID)/utt.wav.

But I also have different est files in my tmp directory, maybe left over from before.

These are not directories, mostly just 44 bytes long (one is 80).

The permissions of the directory it creates:

drwxr-xr-x  2 joel games        176 Jul 16 01:15 est_23219_00001

Hope this helped.

----------

## ootneg

You're right.  While the program is running, the system generates a directory named /tmp/est_PID_xxxxx/, where PID is the process ID of festival, and xxxxx is a number that incraments each time festival synthesizes.  Within this directory are various files.  None of them are the wav file from the error.  This is the error:

 *Quote:*   

> festival> (SayText "test")
> 
> Cannot open file /tmp/est_19344_00013/utt.wav as tokenstream
> 
> Wave load: can't open file "/tmp/est_19344_00013/utt.wav"
> ...

 

I looked for the directory and its contents with the two commands in the same line

 *Quote:*   

> /tmp% ll | grep est ; ll est*
> 
> drwxr-xr-x   2 bob     users       176 Jul 16 18:37 est_19344_00013/
> 
> total 13
> ...

 

All we know from this is that festival is able to write to /tmp/, but that it has errors other than the ones that I was looking for.

----------

## iten

More clues... when I try to say things with a voice that works, the temp files are still created.

```
joel@raven joel $ ls -l /tmp|grep est

-rw-r--r--  1 joel games     529856 Jul 17 08:32 est_13504_00002_aud_00001

-rw-r--r--  1 root root          44 Jul 15 01:37 est_19510_00001

-rw-r--r--  1 root root          44 Jul 15 01:37 est_19510_00003

-rw-r--r--  1 root root          44 Jul 15 01:37 est_19510_00005

-rw-r--r--  1 root root          44 Jul 15 01:37 est_19510_00007

drwxr-xr-x  2 root root          80 Jul 15 01:37 est_19510_00008

-rw-r--r--  1 joel games        867 Jul  3 17:30 test.png
```

And then again, to get a sense of the numbering system:

```

joel@raven joel $ ls -l /tmp/est*

-rw-r--r--  1 joel games 529856 Jul 17 08:33 /tmp/est_13504_00003_aud_00002

-rw-r--r--  1 root root      44 Jul 15 01:37 /tmp/est_19510_00001

-rw-r--r--  1 root root      44 Jul 15 01:37 /tmp/est_19510_00003

-rw-r--r--  1 root root      44 Jul 15 01:37 /tmp/est_19510_00005

-rw-r--r--  1 root root      44 Jul 15 01:37 /tmp/est_19510_00007

```

This is not a directory that it creates, rather what seems to be a text file, however this could be a different stage in the process that I could not catch.

This is what I managed to snag of the file:

```
joel@raven joel $ more /tmp/est_13504_00004_aud_00003 

NIST_1A

   1024

channel_count -i 1

sample_count -i 264416

sample_rate -i 16000

sample_coding -s3 pcm

sample_n_bytes -i 2

sample_byte_format -s2 01

end_head

```

There must be more though, because it seemed like a rather big file...

The real site seems to be permanently gone, so it looks like we're on our own.   :Shocked: 

ootneg:

Did you try packaging up /usr/lib/festival from the working system and transferring it? I'm not sure what difference it would make, but maybe it's worth a shot.

----------

## ootneg

No, I did not do that.  The non working system is behind a non routable firewall, so I have to be on that system to look at it.  From there, I can access the working system.  I compared the files in two side-by-side terminals.  All files are the same size and none appear to be missing.

Just to be sure, I'll do that tomorrow when I'm on the other system again.  I'll pack up the files from the working system and create an MD5 hash.  After I transfer it, I'll check it against the hash and then put it into place.  I'll let you know what happens after I've done that.

----------

## Dr_Smack

I'd just like to toss my hat in the ring as someone for whom festival/text2wave errors.  I, too, watched the /tmp/est_* directories and had the same 5 files as iten.  The file utt.wav never existed.

----------

## ootneg

Looks like the site is back up.  let's hope that it stays up for a goo long while.

I compared the files that I unpacked on the two different systems.  They are identical.  Unfortunately, this means that something else is the problem.  I'm thinking that it must be something with the system configuration. but I don't know where to begin looking.

Maybe, with the site being up at http://hts.ics.nitech.ac.jp/ we can find something that will help.

----------

## fireboy1919

I'm not sure what the problem is for you guys...I can't reproduce it.

I am personally using perl .v5.8.2, speech tools .v1.2.3, and festival-1.4.3-r1 on an x86 machine, so you might look over those dependencies.

Make sure that all the files you put in the lib directory are readable by whatever user you run it as, and that hts_engine and htsvoice.pl are executable by whatever user you run it as...I'm guessing you probably checked that, but just in case...

You might try running each of these and making sure it actually runs and doesn't segfault.  That would give you a good indication of what is failing.

It's rather obvious that these programs make their own wave files independent of festival (I tried to use them with the "singing" portion of festival to no avail).  It would be nice if they made friendly documentation so we could be as well.

----------

## ootneg

My system that can use this voice:

 *Quote:*   

> *  dev-lang/perl :
> 
>         [  I] 5.8.2-r1 (0)
> 
> *  app-accessibility/speech-tools :
> ...

 

My system that cannot use this voice has:

 *Quote:*   

> *  dev-lang/perl :
> 
>         [  I] 5.8.2-r1 (0)
> 
> *  app-accessibility/speech-tools :
> ...

 

I'm sure there are other differences and similarities, but the differences shown above are the kernel (2.4 vs 2.6) and the hardware.

Can we eliminate any of these as being causes of the problem?  If anybody has this working on gentoo-dev-sources (2.6 kernel), then we can eliminate the kernel as the cause.  If someone has compiled this with 

```
CFLAGS="-march=pentium3 . . .
```

and it works, we can eliminate this as being the cause.  I'm thinking of recompiling with less optomization in my CFLAGS if nobody can eliminate this as a cause first.

If someone else has other ideas as to what we can compare, please speek up.

----------

## fireboy1919

I can run this program on both my test and server systems.

Server is running 2.4.23, and the test is running 2.6.6.  A kernel problem would certainly be very difficult to track down.  It's agood thing it's probably not that.

I'm assuming you've tried unmerging and remerging festival?

----------

## Dr_Smack

Well, I'm remerging with very tame CFLAGS now to see if that makes a difference.

I'm running:

2.6.7-gentoo-r10

perl-5.8.4

speech-tools 1.2.3

festival 1.4.3-r1

all on a Celeron 600.  I'll edit this post when it finishes with my results (I'm not holding out much hope).

*EDIT* Nope, didn't change a thing.

*EDIT #2* I've now tried installing and running this on 3 different computers and have had the same results (see previous post) on all 3.

----------

## chrisashton84

I currently get the same error as ootneg and floam.

----------

## ootneg

I recompiled (even unmerged before the new emerge) with no optomizations in my CFLAGS.  This made no difference.  I replaced both speech-tools and festival this way.

Well . . . Back to the old drawing board.

----------

## Chaosite

Hey, this works great for me!

Thanks!

----------

## tridy

getting the same error;

festival> (SayText "help")             

Cannot open file /tmp/est_13432_00000/utt.wav as tokenstream

Wave load: can't open file "/tmp/est_13432_00000/utt.wav"

Cannot load wavefile: /tmp/est_13432_00000/utt.wav

#<Utterance 0x2a96652850>

there seems to be a problem with speech-tools package, don't know if the problem is during compiling or the actual package but all(or lots of)  the scripts/binaries are pointing to PORTAGE_TMPDIR.

for example /usr/lib/speech-tools/bin/tilt_synthesis 

includes

extend LD_LIBRARY_PATH "/home/tmp/portage/portage/speech-tools-1.2.3/work/speech_tools/lib:"

I don't know where this should be pointing, there is about 90 similar examples in /usr/lib/speech-tools. I'm hoping this might help someone figure this out. I'm not certain where to go from here.

----------

## Rafje

 *tridy wrote:*   

> /usr/lib/speech-tools/bin/tilt_synthesis includes extend LD_LIBRARY_PATH "/home/tmp/portage/portage/speech-tools-1.2.3/work/speech_tools/lib:"

 

Hmm. My /usr/lib/speech-tools/bin/tilt_synthesis does not point to a temporary directory:

```
pistache bin # pwd

/usr/lib/speech-tools/bin

pistache bin # cat tilt_analysis | grep LIBR  

extend LD_LIBRARY_PATH "/usr/lib/speech-tools/lib:"

```

 but I have the same "Cannot load wavefile" error as reported above.

So that appears not to be the key issue...

----------

## Rafje

Bingo!

I noticed that I could select voice_us1_mbrola, voice_us2_mbrola and voice_us3_mbrola even before I had emerged mbrola. But when I did select one of those mbrola voices and let festival say something, I got the same "Cannot load wavefile" error.

So, I emerged mbrola, after which the voice_us?_mbrola voices worked. And lo and behold, the voice_cmu_us_slt_arctic_hts magically worked as well. Yay!

So my suggestion is to emerge mbrola and see if it does the trick for you too.

Cheers

----------

## Dr_Smack

 *Rafje wrote:*   

> Bingo!
> 
> I noticed that I could select voice_us1_mbrola, voice_us2_mbrola and voice_us3_mbrola even before I had emerged mbrola. But when I did select one of those mbrola voices and let festival say something, I got the same "Cannot load wavefile" error.
> 
> So, I emerged mbrola, after which the voice_us?_mbrola voices worked. And lo and behold, the voice_cmu_us_slt_arctic_hts magically worked as well. Yay!
> ...

 

I emerged mbrola (which emerged successfully), but the cmu_.... still didn't work.  The mbrola voices did, just not the cmu stuff.

*EDIT* Just for completeness, I tried this method on 3 different machines, all with the same result.

----------

## ootneg

 *Rafje wrote:*   

> Bingo!
> 
> I noticed that I could select voice_us1_mbrola, voice_us2_mbrola and voice_us3_mbrola even before I had emerged mbrola. But when I did select one of those mbrola voices and let festival say something, I got the same "Cannot load wavefile" error.
> 
> So, I emerged mbrola, after which the voice_us?_mbrola voices worked. And lo and behold, the voice_cmu_us_slt_arctic_hts magically worked as well. Yay!
> ...

 

I have had mbrola installed from nearly the beginning of my playing with this program.  It hasn't helped me with getting cmu_us_slt_arctic_hts to work.  Just to be sure, I reinstalled mbrola, but with no change in performance.

----------

## tridy

I emerged mbrola

but with no change.....mmmm.

will have a look at the other error, if Rafje has things pointing to the correct place in speech-tools and mbrola, I'm thinking if I can get things pointing in the right direction it might work.

Dr_Smack and ootneg does your /usr/lib/speech-tools/bin/tilt_analysis and other files in /usr/lib/speech-tools/bin point to the wrong place.

i.e.

extend LD_LIBRARY_PATH "/home/tmp/portage/portage/speech-tools-1.2.3/work/speech_tools/lib:"

exec /home/tmp/portage/portage/speech-tools-1.2.3/work/speech_tools/main/tilt_analysis "$@"

I going blindly here, I don't know if this is the problem but it does seem to be an error. Might be a portage problem? i'm running portage-2.0.50-r9.

----------

## tridy

fixed LD_LIBRARY_PATH problem by updating /usr/portage/app-accessibility/speech-tools. The problem i described seemed to be a known problem.

But I'm still getting 

Cannot open file /tmp/est_16977_00000/utt.wav as tokenstream

Rafje was correct.

----------

## ootneg

 *Quote:*   

> # cat tilt_analysis | grep LIBR  
> 
> extend LD_LIBRARY_PATH "/usr/lib/speech-tools/lib:"

 

Mine has been the same as Rafje's.  I did not need to make this change.

----------

## Dr_Smack

 *tridy wrote:*   

> 
> 
> Dr_Smack and ootneg does your /usr/lib/speech-tools/bin/tilt_analysis and other files in /usr/lib/speech-tools/bin point to the wrong place.
> 
> i.e.
> ...

 

All of mine were correct.  I just did:

```
grep LIBR *

grep exec *
```

Then... just to be sure:

```
grep tmp *
```

All from the /u/l/s-t/bin/ directory.  Nothing was pointing to /tmp/....

----------

## chrisashton84

Here's my guess, it's just a guess, but I think the wav isn't being created.  Since this apparently uses a different engine, has the engine been installed correctly?  I can't tell for sure on mine where it should be.  Any help here?

----------

## Calchan

I had the same problem. I tried a few things, including recompiling the hts_engine executable, but it didn't work. At least, now, I have an über-optimized hts_engine. Enough with suspense, the solution to our problem is:

```
emerge sox
```

Have fun with your new voices.

----------

## tomthewombat

yeah, the perl script runs sox thought a system() call.  would be nice if its left some error messages or a log somewhere when that fails.

----------

## gazoombo

Works for me. ...kinda...

The voices sound fantastic and nothing is broken but I get strange errors mentioning segfaults every time I run festival with the cmu_* voices.

```
mike@gemini ~ $ cat talking.txt | festival --tts

sh: line 1:  4142 Segmentation fault      /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//hts_engine -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_dyn.win -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_acc.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_dyn.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_acc.win -td /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-dur.inf -tm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-mcep.inf -tf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-lf0.inf -md /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//duration.pdf -mm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep.pdf -mf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0.pdf -a 0.420000 -r 0.000000 -fs 1.000000 -fm 0.000000 -om /tmp/est_04135_00000/tmp.mcep -of /tmp/est_04135_00000/tmp.f0 -or /tmp/est_04135_00000/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_04135_00000/tmp.lab >/dev/null

sh: line 1:  4151 Segmentation fault      /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//hts_engine -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_dyn.win -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_acc.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_dyn.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_acc.win -td /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-dur.inf -tm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-mcep.inf -tf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-lf0.inf -md /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//duration.pdf -mm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep.pdf -mf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0.pdf -a 0.420000 -r 0.000000 -fs 1.000000 -fm 0.000000 -om /tmp/est_04135_00002/tmp.mcep -of /tmp/est_04135_00002/tmp.f0 -or /tmp/est_04135_00002/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_04135_00002/tmp.lab >/dev/null

sh: line 1:  4159 Segmentation fault      /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//hts_engine -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_dyn.win -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_acc.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_dyn.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_acc.win -td /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-dur.inf -tm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-mcep.inf -tf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-lf0.inf -md /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//duration.pdf -mm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep.pdf -mf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0.pdf -a 0.420000 -r 0.000000 -fs 1.000000 -fm 0.000000 -om /tmp/est_04135_00004/tmp.mcep -of /tmp/est_04135_00004/tmp.f0 -or /tmp/est_04135_00004/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_04135_00004/tmp.lab >/dev/null

```

----------

## Dr_Smack

 *gazoombo wrote:*   

> Works for me. ...kinda...
> 
> The voices sound fantastic and nothing is broken but I get strange errors mentioning segfaults every time I run festival with the cmu_* voices.
> 
> {snip}

 

I get the segfaults as well.

----------

## tridy

emerge sox gets it working for me

thanks  :Smile: 

talks a bit fast though, will have to get it to slow down!

----------

## crazycat

Works awesome here on amd64. Thanks for the tipp, i had to replace hts_engine with amd64 compiled one.

saytext works pretty good  :Very Happy:  - i tried some dumb things with this f*** word and laughed alot. But i got the following error:

```

#text2wave

/usr/bin/text2wave: line 2: /tmp/portage/festival-1.4.3-r1/work/festival/bin/festival: No such file or directory

/usr/bin/text2wave: line 2: exec: /tmp/portage/festival-1.4.3-r1/work/festival/bin/festival: cannot execute: No such file or directory

```

I assume theese are  some configuration problems but man text2wave did nothing. Do you also know a good frontend for festival?

EDIT: I found out it's a script - and fixed it .

----------

## kpoman

hello again!

i am trying to make this thing work but am also getting the segfault:

```

root@zobiak /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts # text2wave /home/kpoman/mytext

sh: line 1:  2170 Segmentation fault      /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//hts_engine -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_dyn.win -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_acc.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_dyn.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_acc.win -td/usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-dur.inf -tm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-mcep.inf -tf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-lf0.inf -md /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//duration.pdf -mm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep.pdf -mf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0.pdf -a 0.420000 -r 0.000000 -fs 1.000000 -fm 0.000000 -om /tmp/est_02164_00000/tmp.mcep -of /tmp/est_02164_00000/tmp.f0 -or /tmp/est_02164_00000/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_02164_00000/tmp.lab >/dev/null

Cannot open file /tmp/est_02164_00000/utt.wav as tokenstream

Wave load: can't open file "/tmp/est_02164_00000/utt.wav"

Cannot load wavefile: /tmp/est_02164_00000/utt.wav

root@zobiak /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts #        

...

```

i compiled from sources the hts_engine just in case that was the problem i was having, but no luck !

i tried also compiling sox, but that did not help. i am able to switch to an mbrola voice, and then if i switch to the arctic one, it works (it complains and segfaults though, but i hear the new voice and it sounds cool !):

```

root@zobiak /usr/lib/festival/voices/english # festival

Festival Speech Synthesis System 1.4.3:release Jan 2003

Copyright (C) University of Edinburgh, 1996-2003. All rights reserved.

For details type `(festival_warranty)'

festival>  (voice_us1_mbrola)

us1_mbrola

festival>  (SayText "Good morning, welcome to Festival")

#<Utterance 0x407301f8>

festival>  (voice_cmu_us_slt_arctic_hts)

cmu_us_slt_arctic_hts

festival>  (SayText "Good morning, welcome to Festival")

sh: line 1:  6973 Segmentation fault      /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//hts_engine -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_dyn.win -dm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep_acc.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_dyn.win -df /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0_acc.win -td/usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-dur.inf -tm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-mcep.inf -tf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//tree-lf0.inf -md /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//duration.pdf -mm /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//mcep.pdf -mf /usr/lib/festival/voices/english/cmu_us_slt_arctic_hts/hts//lf0.pdf -a 0.420000 -r 0.000000 -fs 1.000000 -fm 0.000000 -om /tmp/est_06952_00001/tmp.mcep -of /tmp/est_06952_00001/tmp.f0 -or /tmp/est_06952_00001/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_06952_00001/tmp.lab >/dev/null

#<Utterance 0x40783438>

festival>  (voice_us1_mbrola)

us1_mbrola

festival>  (SayText "Good morning, welcome to Festival")

#<Utterance 0x40948958>

festival>            

```

do someone know what is going on here ?  help much appreciated! i would really like havin my audiobooks  :Smile:  thanks !

----------

## Heiga Zen

Hi, my name is Heiga Zen.

I am maintaining and developping HMM-based speech synthesis toolkit.

Today I visited this forum for the first time.

I was very surprised  :Very Happy: 

I'd like to commit to this forum.

If you are interested in developping HMM-based speech synthesis system,

please join our hts-users mailing list.

Next version of festival (2.0?) will include HTS as a module.

Curret HTS voices requires sox, and perl.

I think it causes a lot of problems for you.

I'm very sorry   :Crying or Very sad: 

But next version does not require them.

Festival 1.95beta has been released already.

(http://www.festvox.org/festival/index.html)

(HTS voices are included initially)

I recommend you to try to use it.

Please give me your feedback.

Thank you very much

P.S. Our web server crushed from July 6th to 21st.

       I'm sorry for your inconvienience   :Crying or Very sad: 

----------

## tridy

 *Quote:*   

> Festival 1.95beta has been released already.
> 
> (http://www.festvox.org/festival/index.html)
> 
> (HTS voices are included initially)
> ...

 

I tried compiling speech_tools-1.2.95-beta for festival-1.95-beta with gcc-3.3.4-r1.

I did 

```
./configure
```

and 

```
make(gmake)
```

but it seems to go in a loop

```

./config.status

creating config/config

Check system type

Remake modincludes.inc

        NATIVE_AUDIO

                ok

        EDITLINE

                config/modules/editline.mak

        SIOD

                siod/siod.mak

        WAGON

                stats/wagon/wagon.mak

        SCFG

                grammar/scfg/scfg.mak

        WFST

                grammar/wfst/wfst.mak

        OLS

                stats/ols.mak

        RXP

                rxp/rxp.mak

        LINUX16_AUDIO

                config/modules/linux16_audio.mak

./config.status

creating config/config

Check system type

Remake modincludes.inc

        NATIVE_AUDIO

                ok

        EDITLINE

                config/modules/editline.mak

        SIOD

                siod/siod.mak

        WAGON

                stats/wagon/wagon.mak

        SCFG

                grammar/scfg/scfg.mak

        WFST

                grammar/wfst/wfst.mak

        OLS

                stats/ols.mak

        RXP

                rxp/rxp.mak

        LINUX16_AUDIO

                config/modules/linux16_audio.mak

```

am I doing anything wrong?

----------

## lisa

 *fireboy1919 wrote:*   

> Check if you have ispell with emerge (emerge -s ispell).  Check if you have Lingua::Ispell by using CPAN.  To do this, type
> 
> ```
> perl -MCPAN -e shell
> ```
> ...

 

NOOOOOOOOOOOOOOOOOOOOOOOO!!!!!!!!!!!!!!!!!!!

Use 

```
g-cpan.pl Lingua::Ispell
```

----------

## Vanquirius

 *Heiga Zen wrote:*   

> Hi, my name is Heiga Zen.
> 
> I am maintaining and developping HMM-based speech synthesis toolkit.

 

Thank you very much for this fine piece of software.

One tip I would like to share with fellow users is to compile their own hts_engine:

```
-rwxr-xr-x  1 root root  37K Sep 19 15:43 hts_engine

-rwxr-xr-x  1 4426 4420 1.6M Dec 26  2003 hts_engine.old
```

----------

## Heiga Zen

 *Vanquirius wrote:*   

> 
> 
> ```
> -rwxr-xr-x  1 root root  37K Sep 19 15:43 hts_engine
> 
> ...

 

Sorry, I don't get you   :Crying or Very sad: 

What is the difference between "hts_engine" and "hts_engine.old" ?

If "hts_engine.old" is binary file included in our voice distributions

and "hts_engine" is one which was compiled from source files, 

file size difference between them is caused from compiling option.

"hts_engine.old" is "statically" compiled one (with -static option).

This is because that file size of "hts_engine.old" is larger than that of "hts_engine".Last edited by Heiga Zen on Thu Sep 23, 2004 2:57 pm; edited 1 time in total

----------

## Vanquirius

Oh, I see. My bad, I thought that was due to lower optimizations, but I see you are right...

```
marcelo@revolvo hts $ ldd hts_engine

        linux-gate.so.1 =>  (0xffffe000)

        libm.so.6 => /lib/libm.so.6 (0x41695000)

        libc.so.6 => /lib/libc.so.6 (0x4157d000)

        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x4107e000)

marcelo@revolvo hts $ ldd hts_engine.old

        not a dynamic executable
```

Pardon my ignorance.

----------

## MaineZJ

I have recently been trying to use Festival with a project....

I noticed that Festival installs to /usr/share/festival

and when I install mbrola, it's extra voices are installed to /usr/lib/festival

did this to make us1 voice work:

ln -s /usr/lib/festival/voices/english/us1_mbrola/us1 /usr/share/festival/voices/english/us1_mbrola/us1

----------

## telegenetic

i was getting this error also i then looked into htsvoice.pl and noticed this line

  system("sox -r $SAMPRATE -t raw -s -c 1 -w $WORKDIR/tmp.raw $OUTWAVE");

  noticed WORKDIR is tmp 

  did a USE="-xorg" emerge sox and it works

----------

## bitwise

wow, these sound great, glad I found this thread

Only issue here is the weird seg faults that occur. I still hear the text and everything but I get this:

```
$ sh: line 1:  3826 Segmentation fault      /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//hts_engine -dm /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//mcep_dyn.win -dm /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//mcep_acc.win -df /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//lf0_dyn.win -df /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//lf0_acc.win -td /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//tree-dur.inf -tm /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//tree-mcep.inf -tf /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//tree-lf0.inf -md /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//duration.pdf -mm /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//mcep.pdf -mf /usr/lib/festival/voices/english/cmu_us_jmk_arctic_hts/hts//lf0.pdf -a 0.420000 -r 0.000000 -fs 1.000000 -fm 0.000000 -om /tmp/est_03820_00000/tmp.mcep -of /tmp/est_03820_00000/tmp.f0 -or /tmp/est_03820_00000/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_03820_00000/tmp.lab >/dev/null
```

spewing onto my console, anyone have a fix?

----------

## Wi1d

 *Saburo wrote:*   

> wow, these sound great, glad I found this thread
> 
> Only issue here is the weird seg faults that occur. I still hear the text and everything but I get this:
> 
> ```
> ...

 

Your not the only one. I'm getting the same error so *bump*

----------

## mirko_3

I just tried it, I also get this error. Any solution?

----------

## VinzC

Hi all.

I've been able to download french database files (e.g. fr1 - fr7) but I'm lacking the *.scm files (e.g. fr1_mbrola.scm). Does anyone know how/where I can get these kinds of files?

Thanks in advance.

----------

## Headhunter123

This new speech engine works great! Festival is finally understandable, very nice work!

One thing which came up my mind and might be really useful might be a plugin

for firefox, where you select some text and let it read to you by festival.

I usually don't read books at the pc, but i browse a lot of news pages, having them 

read to me would be great - anything done like that yet?

----------

## telegenetic

I had this working awhile ago, I reinstalled today and it kept seg faulting like others have.

 I diff'ed the old text2wave to the new one and have this:

143c143

<   (let ((wholeutt (Utterance Text "")))

---

>   (let ((wholeutt (utt.synth (Utterance Text ""))))

 So on the _new_ text2wave on line 143 i changed:

   (let ((wholeutt (utt.synth (Utterance Text ""))))

 to

   (let ((wholeutt (Utterance Text "")))

 No more seg faults.

 The whole thing:

 tar -xvzf speech_tools-1.2.95-beta.tar.gz

 cd speech_tools

 ./configure

 make

 cd ..

 tar -xvzf festival-1.95-beta.tar.gz

 tar -xvzf festlex_CMU.tar.gz

 tar -xvzf festlex_OALD.tar.gz

 tar -xvzf festlex_POSLEX.tar.gz

 tar -xvzf festvox_cmu_us_awb_arctic_hts.tar.gz

 tar -xvzf festvox_cmu_us_bdl_arctic_hts.tar.gz

 tar -xvzf festvox_cmu_us_jmk_arctic_hts.tar.gz

 tar -xvzf festvox_cmu_us_slt_arctic_hts.tar.gz

 tar -xvzf festvox_cstr_us_awb_arctic_multisyn-1.0.tar.gz

 tar -xvzf festvox_cstr_us_jmk_arctic_multisyn-1.0.tar.gz

 tar -xvzf festvox_don.tar.gz

 tar -xvzf festvox_ellpc11k.tar.gz

 tar -xvzf festvox_en1.tar.gz

 tar -xvzf festvox_kallpc16k.tar.gz

 tar -xvzf festvox_kallpc8k.tar.gz

 tar -xvzf festvox_kedlpc16k.tar.gz

 tar -xvzf festvox_kedlpc8k.tar.gz

 tar -xvzf festvox_rablpc16k.tar.gz

 tar -xvzf festvox_rablpc8k.tar.gz

 tar -xvzf festvox_us1.tar.gz

 tar -xvzf festvox_us2.tar.gz

 tar -xvzf festvox_us3.tar.gz

 cd festival

 ./configure

  make

  make tests

 fix line 143 in bin/text2wave and you should be good.

 luca

----------

## Massimo B.

Being on ppc I had to rebuild the binary, then it's executable (at least without argument).

But starting a festival sentence crashes:

```
# echo "I'm this annoying little blonde speaking from a Gentoo Box" | festival --tts

*** glibc detected *** /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//hts_engine: munmap_chunk(): invalid pointer: 0x100bfcfc ***

======= Backtrace: =========

/lib/libc.so.6(__libc_free+0x1f4)[0xfe2c2ec]

/usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//hts_engine[0x10002b9c]

/usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//hts_engine[0x1000378c]

/usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//hts_engine[0x10000f94]

/usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//hts_engine[0x10001a30]

/lib/libc.so.6[0xfdcd690]

/lib/libc.so.6(__libc_start_main+0x130)[0xfdcd894]

======= Memory map: ========

00100000-00102000 r-xp 00100000 00:00 0

0fdaf000-0fefb000 r-xp 00000000 03:04 6298378    /lib/libc-2.4.so

0fefb000-0ff0b000 ---p 0014c000 03:04 6298378    /lib/libc-2.4.so

0ff0b000-0ff0d000 r--p 0014c000 03:04 6298378    /lib/libc-2.4.so

0ff0d000-0ff10000 rwxp 0014e000 03:04 6298378    /lib/libc-2.4.so

0ff10000-0ff13000 rwxp 0ff10000 00:00 0

0ff23000-0ffda000 r-xp 00000000 03:04 6299726    /lib/libm-2.4.so

0ffda000-0ffe9000 ---p 000b7000 03:04 6299726    /lib/libm-2.4.so

0ffe9000-0ffea000 r--p 000b6000 03:04 6299726    /lib/libm-2.4.so

0ffea000-0fff0000 rwxp 000b7000 03:04 6299726    /lib/libm-2.4.so

10000000-10008000 r-xp 00000000 03:04 8002561    /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts/hts_engine

10017000-10018000 rwxp 00007000 03:04 8002561    /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts/hts_engine

10018000-1028b000 rwxp 10018000 00:00 0          [heap]

30000000-3001f000 r-xp 00000000 03:04 6299664    /lib/ld-2.4.so

3001f000-30022000 rw-p 3001f000 00:00 0

3002e000-3002f000 r--p 0001e000 03:04 6299664    /lib/ld-2.4.so

3002f000-30030000 rwxp 0001f000 03:04 6299664    /lib/ld-2.4.so

30030000-30110000 rw-p 30030000 00:00 0

7ff7b000-7ff91000 rw-p 7ff7b000 00:00 0          [stack]

sh: line 1: 17428 Abgebrochen             /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//hts_engine -dm /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//mcep_dyn.win -dm /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//mcep_acc.win -df /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//lf0_dyn.win -df /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//lf0_acc.win -td /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//tree-dur.inf -tm /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//tree-mcep.inf -tf /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//tree-lf0.inf -md /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//duration.pdf -mm /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//mcep.pdf -mf /usr/share/festival/voices/us/cstr_us_ked_timit_hts/hts//lf0.pdf -a 0.420000 -r 0.100000 -fs 1.000000 -fm 0.000000 -om /tmp/est_17401_00000/tmp.mcep -of /tmp/est_17401_00000/tmp.f0 -or /tmp/est_17401_00000/tmp.raw -u 0.500000 -l 0.000000 -b 0.300000 /tmp/est_17401_00000/tmp.lab > /dev/null
```

http://hts.ics.nitech.ac.jp/release/HTS-1.1.1_for_HTK-3.2.1.tar.gz

I also tried to built the binary with different CFLAGS. Afterwards I just copied the binary over to the voices directory where the i386 precompiled hts_engine was.

----------

## Heiga Zen

Hi all,

The HTS working group has released the new version of HMM-based speech synthesis system (HTS version 2.0).

6 new voices (4 male and 2 female) for Festival 1.95 and later were also released.

Some of the speakers in the new voices were the same as those in the previous version, but they are trained with the new technologies.

I think new ones sounds better than the previous version, please try it   :Very Happy: 

You can download them from http://hts.ics.nitech.ac.jp/

----------

## Heiga Zen

HTS website moved to http://hts.sp.nitech.ac.jp/

----------

## Massimo B.

I set up some scripts to issue voice messages.

Now what is the difference between using the festival init script starting a server daemon and using the /dev/speech device OR the usual call approach?

```
echo "Lost power. Powersave mode." |festival --tts
```

----------

## zaai

The  CMU ARCTIC Databases, especially the US English slt (female) sounds pretty good. Much better than the pure HTS version of these voices.

Only when words aren't in the dictionary it falls back to diphones which unfortunately adds the nasty hickups.

----------

## vap0rtranz

I'll listen to Salt (voice_cmu_us_slt_arctic_hts) anyday when given the choice between her and Mbrola -- ick.

One issue here.  When I pipe text files to festival or when I read files from festival's console, the voice starts fine, then there's two of them talking, and next thing she's skipped a few words.  Eitherway:

```
head ~/docs/livejournal.com/freedom-clean.txt | festival --tts
```

```
~ $ festival

Festival Speech Synthesis System 1.95:beta July 2004

Copyright (C) University of Edinburgh, 1996-2004. All rights reserved.

For details type `(festival_warranty)'

festival> (tts "/home/jrpittma/docs/livejournal.com/freedom-clean.txt" nil)
```

At first I thought newline characters or other text file ilk was getting her confused but I purged those with the perl script posted on the top of this thread.  So is this a conflict between festival -> esound -> alsa? because I had to start esd to get anything more than /dev/speech working ...  (esound is evil   :Evil or Very Mad:  )

----------

## Massimo B.

This is also my favorite voice talking to my all the time about new emails, successfull or failed emerges, cron-jobs...

I set it to use alsa:

```
(Parameter.set 'Audio_Command "aplay -q -c 1 -t raw -f s16 -r $SR $FILE")
```

I don't have these problems you describe.

----------

## vap0rtranz

 *Quote:*   

> I set it to use alsa:

 

I found out that festival's developers enable audio spooling by default and I was actually hearing the beginning of the next sentence before the end of the previous.  Instead of manually playing around with an Audio_Command, I simply switched to the well-known linux audio:

```
$ grep linux /etc/festival/siteinit.scm

(Parameter.set 'Audio_Method 'linux16audio)
```

And tada! the console works.  According to their doc, that module sends audio to /dev/dsp which is controlled by alsa on my box -- totally circumventing esound.   :Smile: 

But text2wave segfaults if I use the sexy Salt voice (and the festival guys say that their example programs require the diphone voices: "[The test suite] assumes that voice_rab_diphone (`festvox_rabxxxx.tar.gz') is the default voice ...").  Have you recorded her voice to wave files?  If so, how? And do you have esd running? or just alsa?

----------

## Massimo B.

What do you mean about segfaults? Sometimes I get underrun!!! (at least 382,568 ms long), but I think that's my slow machine.

There's only Alsa, no esd running.

----------

## vap0rtranz

I mean, if:

```
 $ grep voice ~/.festivalrc 

(voice_rab_diphone)

(set! voice_default 'voice_cmu_us_slt_arctic_hts)
```

then:

```

$ text2wave -F 44100 -o freedom.wav ~/docs/livejournal.com/freedom-short.txt

Segmentation fault

$ aplay freedom.wav

freedom.wav: No such file or directory
```

else if:

```
$ grep voice ~/.festivalrc 

(voice_rab_diphone)

;(set! voice_default 'voice_cmu_us_slt_arctic_hts)
```

then:

```
$ aplay freedom.wav 

Playing WAVE 'freedom.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Mono
```

And the British dude tries his best to talk about freedom.    :Crying or Very sad: 

----------

## vap0rtranz

 *Massimo B. wrote:*   

> What do you mean about segfaults? Sometimes I get underrun!!! (at least 382,568 ms long), but I think that's my slow machine.

 

P.S.  Someone else had this problem about a year ago so I bumped it up ...  And I get the underrun errors on long chunks of text but it doesn't segfault.

----------

## starseeker

festival-1.95_beta-r4  USE="X -asterisk -esd -mbrola"

~/.festivalrc:

(voice_rab_diphone)

(set! voice_default 'voice_cmu_us_slt_arctic_hts)

festival --tts test.txt 

Duration tree extreme for r 3.64693

Duration tree extreme for r 3.64693

Duration tree extreme for r 3.64693

(successful, plays on speakers.)

./text2wave -o test.wav test.txt 

Duration tree extreme for r 3.64693

Duration tree extreme for r 3.64693

Duration tree extreme for r 3.64693

Segmentation fault

(no wav file  :Sad:  failure)

----------

## starseeker

An interesting data point - I don't know quite why, or who's fault it is, but when I try to work around this by using vsound the temporary file generated by vsound itself keeps getting re-set in file size:

417816 Jul 21 12:22 vsound20441.au

417816 Jul 21 12:22 vsound20441.au

24600 Jul 21 12:22 vsound20441.au

32792 Jul 21 12:22 vsound20441.au

40984 Jul 21 12:22 vsound20441.au

49176 Jul 21 12:22 vsound20441.au

57368 Jul 21 12:22 vsound20441.au

65560 Jul 21 12:22 vsound20441.au

73752 Jul 21 12:22 vsound20441.au

81944 Jul 21 12:22 vsound20441.au

90136 Jul 21 12:22 vsound20441.au

98328 Jul 21 12:22 vsound20441.au

106520 Jul 21 12:22 vsound20441.au

122904 Jul 21 12:22 vsound20441.au

131096 Jul 21 12:22 vsound20441.au

139288 Jul 21 12:22 vsound20441.au

147480 Jul 21 12:22 vsound20441.au

155672 Jul 21 12:22 vsound20441.au

163864 Jul 21 12:22 vsound20441.au

163864 Jul 21 12:22 vsound20441.au

16408 Jul 21 12:22 vsound20441.au

24600 Jul 21 12:22 vsound20441.au

32792 Jul 21 12:22 vsound20441.au

131096 Jul 21 12:22 vsound20441.au

147480 Jul 21 12:22 vsound20441.au

In the end, all I got in vsound.wav was the last word.  Does something about the way this voice works make festival re-set something internally every so often?

----------

## vap0rtranz

Where did you find those .au files and .wav??

----------

## starseeker

When I tried the following:

vsound -d festival --tts test.txt 

I then opened another xterm and went to that same directory, and watched the temporary au file with ls -l *.au

I used a long enough test file to give me some time to watch.

----------

## vap0rtranz

Interesting.  I see files created in /tmp like the guy above in the thread ... and they are playable, as if we could manually concatenate them into one big wav file *evil grin*

Switching to the alsa-drivers in portage and yanking ALSA out of my kernel did not fix the text2wave segfaults.  A slight alteration to Massimo's config got me working again aftewards -- using jack here so I had to call $aplay -Djackplug

/etc/festival/siteinit.scm:

```
(Parameter.set 'Audio_Command "aplay -Djackplug -q -c 1 -t raw -f s16 -r $SR $FILE")
```

Something changed that did not like festival's linux16audio parameter ...

----------

## starseeker

Well, as a workaround the combination of the method change and vsound seems to work here:

/etc/festival/siteinit.scm:

(Parameter.set 'Audio_Method 'linux16audio)

(set! voice_default 'voice_cmu_us_slt_arctic_hts)

(provide 'siteinit)

vsound --timing -f test.wav -d festival --tts test.txt

----------

## starseeker

Confound it.  Even that doesn't work.  vsound is still resetting itself periodically.  And when I break it down to one word a line, I can't cat the wav files together.  The only way it works is putting it through sox, which gives me a big space after each word.

Grr.

----------

## thewtex

Dudes, I think I have the ALSA problem figured out.  sox, vsound, esd are all OSS based, so they may not work very well on a modern system.  See

http://gentoo-wiki.com/HOWTO_speechd

in the text to .wav section.

I think when you use use native text2wave script it works much faster than real time, but this works.

Also, it seems like it is pretty easy to record any sound going through your system with arecord.

Please let me know if you make any improvements.

----------

## thewtex

Note: script had a big boo-boo for text files not ending in .txt-- fixed that now.

----------

## tkhemili78

im coming up with a strange problem

i have installed 

festival 1.96

sox-14

speechd-.56

speech-tools-1.2.96

at this point I am not able to use any of the cmu voices

the error that pops up says something about hts_engine not being compiled

anyone else no whats up ?

----------

## tkhemili78

I solved my issue

I downgraded festival to 1.95

copied the voices from /usr/share/festival/voices to /usr/lib/festival/voices

and 

BINGO !!!!

(no gramma were not playing bingo yet LOL)

----------

## Massimo B.

Since 1.96_beta became stable on ppc there's the same problem here.

Did they discard these voices? /usr/share/festival/voices still has the selected voice.

```
# echo "Hello. I'm the Apple Powerbook G4 running Gentoo Linux." |festival --tts

SIOD ERROR: module hts_engine required, but not compiled in this installation

closing a file left open: /usr/share/festival/voices/us/cmu_us_slt_arctic_hts/festvox/cmu_us_slt_arctic_hts.scm

closing a file left open: /usr/share/festival/init.scm

festival: fatal error exiting.
```

Copying from  /usr/share/festival/voices to /usr/lib/festival/voices  did not help.

----------

## violagirl

How do you guys have text2wave anyway? I emerged festival and I don't have the command at all.    :Confused: 

----------

## ddc

 *violagirl wrote:*   

> How do you guys have text2wave anyway? I emerged festival and I don't have the command at all.   

 

it is not a command, it is an example ... see /usr/share/doc/festival/examples ... you will find it

unfortunately 

festival 1.96 "hts_engine required, but not compiled in this installation"

festival 1.95 "SIOD ERROR: damaged env : #<UNKNOWN 12 0x3019fe18>"

----------

