Skip to content

Commit

Permalink
fix typo in previous commit
Browse files Browse the repository at this point in the history
  • Loading branch information
rsennrich committed Jun 28, 2018
1 parent 61ad855 commit 48ba99e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion subword_nmt/learn_bpe.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ def learn_bpe(infile, outfile, num_symbols, min_frequency=2, verbose=False, is_d
for word in vocab:
for char in word[:-1]:
uniq_char_internal.add(char)
uniq_char_final.add(char[-1])
uniq_char_final.add(word[-1])
sys.stderr.write('Number of word-internal characters: {0}\n'.format(len(uniq_char_internal)))
sys.stderr.write('Number of word-final characters: {0}\n'.format(len(uniq_char_final)))
sys.stderr.write('Reducing number of merge operations by {0}\n'.format(len(uniq_char_internal) + len(uniq_char_final)))
Expand Down

0 comments on commit 48ba99e

Please sign in to comment.