From 8cc03572e53a0be3d6ce55c46b76b4c32882f5ed Mon Sep 17 00:00:00 2001 From: Piero Toffanin Date: Fri, 1 Apr 2022 10:01:15 -0400 Subject: [PATCH] Fix install_models.py --- install_models.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/install_models.py b/install_models.py index a6aa2ef..e610230 100755 --- a/install_models.py +++ b/install_models.py @@ -6,6 +6,8 @@ if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument("--load_only_lang_codes", type=str, default="") args = parser.parse_args() - lang_codes = args.load_only_lang_codes.split(",") or None + lang_codes = args.load_only_lang_codes.split(",") + if len(lang_codes) == 0: + lang_codes = None check_and_install_models(force=True, load_only_lang_codes=lang_codes) check_and_install_transliteration(force=True)