From 61fa1ad428e9f84e4e6cfb54056dfeaf2436c062 Mon Sep 17 00:00:00 2001 From: Alexandre Lissy Date: Fri, 6 Mar 2020 10:13:18 +0100 Subject: [PATCH] Show actual alphabet path in error message --- util/text.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/text.py b/util/text.py index d3be7eb8..253d2291 100644 --- a/util/text.py +++ b/util/text.py @@ -33,9 +33,9 @@ class Alphabet(object): return self._str_to_label[string] except KeyError as e: raise KeyError( - 'ERROR: Your transcripts contain characters (e.g. \'{}\') which do not occur in data/alphabet.txt! Use ' \ + 'ERROR: Your transcripts contain characters (e.g. \'{}\') which do not occur in \'{}\'! Use ' \ 'util/check_characters.py to see what characters are in your [train,dev,test].csv transcripts, and ' \ - 'then add all these to data/alphabet.txt.'.format(string) + 'then add all these to \'{}\'.'.format(self._config_file, string, self._config_file) ).with_traceback(e.__traceback__) def has_char(self, char):