Commit 2efdfb12 authored by Gaurav Kumar's avatar Gaurav Kumar
Browse files

(Fisher-Callhome-Spanish) : Modified license for spron.pl. Segments with the...

(Fisher-Callhome-Spanish) : Modified license for spron.pl. Segments with the same start and end time do not get added to the segments file anymore

git-svn-id: https://svn.code.sf.net/p/kaldi/code/trunk@4554 5e6a8d80-dfce-4ca6-a32a-6e07a63d50c8
parent a8c505f9
......@@ -40,7 +40,7 @@ cd $dir
# Make directory of links to the WSJ disks such as 11-13.1. This relies on the command
# line arguments being absolute pathnames.
rm -r links/ 2>/dev/null
#rm -r links/ 2>/dev/null
mkdir links/
ln -s $* links
......
......@@ -140,7 +140,7 @@ if [ $stage -le 2 ]; then
&& echo "Error producing utt2spk file" && exit 1;
cat $dir/train_all/text | perl -ane 'm:((\S+-[AB])-(\d+)-(\d+))\s: || die; $utt = $1; $reco = $2;
$s = sprintf("%.2f", 0.01*$3); $e = sprintf("%.2f", 0.01*$4); print "$utt $reco $s $e\n"; ' >$dir/train_all/segments
$s = sprintf("%.2f", 0.01*$3); $e = sprintf("%.2f", 0.01*$4); if ($s != $e) {print "$utt $reco $s $e\n"}; ' >$dir/train_all/segments
$utils/utt2spk_to_spk2utt.pl <$dir/train_all/utt2spk > $dir/train_all/spk2utt
fi
......
#!/usr/bin/perl
# Oct 21, 2015 : Gaurav Kumar (Johns Hopkins University)
# Apache 2.0
# GNU General Public License, v3.0
#
# This script was modified under GPL and is being distributed with
# Kaldi under a new license. It requires the preference and rule files
# Kaldi. It requires the preference and rule files
# (under LDC copyright) from LDC96L16. The main changes were
# - Outdated usage of perl conventions updated @_ => $_ or @A
# - This script no longer needs the preference and rule files to
# be in the same directory as this script.
# - Accepts tokens from <STDIN> instead of <>
# --- Retained previous version information ----------------------------
# spron.pl Version 0.1 Jan. 11 1995
# Written by Zhibiao Wu, LDC, wzb@unagi.cis.upenn.edu
# This program needs the basic_rules file to run. The rules must be sorted
......@@ -28,6 +29,7 @@
# - look for basic_rules and preferences in $PWD instead of ~wzb/...
# - use next to shortcut loop instead of if/else
# - added a bit of documentation, without really trying to decipher this thing
# -----------------------------------------------------------------------
$vfile = "";
$preference_file = "";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment