- Timestamp:
- 05/27/08 12:38:46 (6 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
Trunk/Scripts/Audio_scripts/AudioSegmentation/AudioBook.pm
r2594 r2595 81 81 =head1 REQUIREMENTS 82 82 83 =item 1 - Sequitor G2P trainable Grapheme-to-Phoneme converter ( whichrequires Python to be installed)83 =item 1 - Sequitor G2P trainable Grapheme-to-Phoneme converter (GPL v2; requires Python to be installed) 84 84 85 85 http://www-i6.informatik.rwth-aachen.de/web/Software/g2p.html … … 88 88 89 89 http://htk.eng.cam.ac.uk/ 90 91 The HTK toolkit needs to be in your path (see http://www.voxforge.org/home/dev/acousticmodels/linux/create/htkjulius/tutorial/download) 90 92 91 93 =head1 ALGORITHM … … 166 168 close LOG 167 169 } 168 # dict may get manually updated; dict only includes suggested prompts 170 # dict may get manually updated; dict only includes suggested prompts, therefore do not copy to output - suggested pronunications are in the log regardless ... 169 171 #... $command = ("cp AudioBook/interim_files/dict AudioBook/output_files"); print "cmd:$command\n" if $debug; system($command); 170 $command = ("cp AudioBook/interim_files/prompts AudioBook/output_files/prompts"); print "cmd:$command\n" if $debug; system($command);171 172 172 173 my $audio = AudioBook::Audio->new($self); … … 182 183 =head2 cleanupFiles 183 184 184 Removes any old files in the AudioBook/interim_files/ and AudioBook/output_files/ directories .185 Removes any old files in the AudioBook/interim_files/ and AudioBook/output_files/ directories, prior to processing. 185 186 186 187 =cut … … 228 229 $mday = sprintf("%02d", $mday); 229 230 print "creating gzipped tar file:$username\-$year$mon$mday\-$tarSuffix\.tgz \n"; 230 # !!!!!!231 #$command = ("cp $readme AudioBook/output_files/README"); print "cmd:$command\n" if $debug; system($command);232 231 if (defined($readme)) { 233 232 copy("$readme","AudioBook/output_files/README"); … … 235 234 print "Warning: no README file to copy\n"; 236 235 } 237 #$command = ("cp $license AudioBook/output_files/LICENSE"); print "cmd:$command\n" if $debug; system($command);238 236 if (defined($license)) { 239 237 copy("$license","AudioBook/output_files/LICENSE"); … … 241 239 print "Warning: no LICENSE file to copy\n"; 242 240 } 241 copy("AudioBook/interim_files/prompts","AudioBook/output_files/prompts"); 243 242 $command = ("cp AudioBook/interim_files/wav/* AudioBook/output_files/wav/"); print "cmd:$command\n" if $debug; system($command); 244 # !!!!!!245 243 if ($debug) { 246 244 $command = ("tar -zcvf $username\-$year$mon$mday\-$tarSuffix\.tgz AudioBook/output_files --exclude \"\.svn\" "); print "cmd:$command\n" if $debug; system($command); … … 270 268 my ($self)= @_; 271 269 my $debug = $self->{'debug'}; 272 getopts('a:b:d:hl:m:p:r:s:t:u:x:q:v :ST'); # sets $opt_* as a side effect.270 getopts('a:b:d:hl:m:p:r:s:t:u:x:q:vST'); # sets $opt_* as a side effect. 273 271 if ($opt_a and $opt_t) { 274 272 if (-r $opt_a) { … … 322 320 } 323 321 if ($opt_v) { 324 if ($opt_v =~ /^y|yes$/i) { 325 $self->{"verify_segments"}=1; 326 } else { 327 $self->{"verify_segments"}=0; 328 } 322 $self->{"verify_segments"}=1; 329 323 } else { 330 324 $self->{"verify_segments"}=0; … … 401 395 print "\n\t* required for script to run\n"; 402 396 print "\n"; 397 print "--\n"; 398 print "Free Speech... Recognition\n"; 399 print "http://www.voxforge.org\n\n"; 403 400 exit; 404 401 } else { … … 406 403 print "==================================\n"; 407 404 print "Parms -a and -t need to be defined. Use -h parameter for more information\n\n"; 405 print "--\n"; 406 print "Free Speech... Recognition\n"; 407 print "http://www.voxforge.org\n\n"; 408 408 exit; 409 409 }