Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ GSYMS
/tools/ATLAS/
/tools/atlas3.8.3.tar.gz
/tools/irstlm/
/tools/mitlm/
/tools/openfst
/tools/openfst-1.3.2.tar.gz
/tools/openfst-1.3.2/
Expand Down
4 changes: 2 additions & 2 deletions egs/babel/s5d/conf/lang/404-georgian.FLP.official.conf
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ unsup_data_list=./conf/lists/404-georgian/untranscribed-training.list
unsup_nj=32


lexicon_file=
lexiconFlags="--romanized --oov <unk>"
lexicon_file=/export/corpora/LDC/LDC2016S12/IARPA_BABEL_OP3_404/conversational/reference_materials/lexicon.txt
lexiconFlags=" --romanized --oov <unk>"



14 changes: 10 additions & 4 deletions egs/babel/s5d/local/make_L_align.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,24 @@ tmpdir=$1
dir=$2
outdir=$3

for f in $dir/phones/optional_silence.txt $dir/phones.txt $dir/words.txt ; do
[ ! -f $f ] && echo "$0: The file $f must exist!" exit 1
fi

silphone=`cat $dir/phones/optional_silence.txt` || exit 1;

if [ ! -f $tmpdir/lexicon.txt ] && [ ! -f $tmpdir/lexiconp.txt ] ; then
echo "$0: At least one of the files $tmpdir/lexicon.txt or $tmpdir/lexiconp.txt must exist" >&2
exit 1
fi

# Create lexicon with alignment info
if [ -f $tmpdir/lexicon.txt ] ; then
cat $tmpdir/lexicon.txt | \
awk '{printf("%s #1 ", $1); for (n=2; n <= NF; n++) { printf("%s ", $n); } print "#2"; }'
elif [ -f $tmpdir/lexiconp.txt ] ; then
else
cat $tmpdir/lexiconp.txt | \
awk '{printf("%s #1 ", $1); for (n=3; n <= NF; n++) { printf("%s ", $n); } print "#2"; }'
else
echo "Neither $tmpdir/lexicon.txt nor $tmpdir/lexiconp.txt does not exist"
exit 1
fi | utils/make_lexicon_fst.pl - 0.5 $silphone | \
fstcompile --isymbols=$dir/phones.txt --osymbols=$dir/words.txt \
--keep_isymbols=false --keep_osymbols=false | \
Expand Down