From 754720a328735d3d48e8186c788cfa12cb4a3468 Mon Sep 17 00:00:00 2001 From: zhijianma Date: Fri, 24 Nov 2023 21:23:58 +0800 Subject: [PATCH] fix: remove extra prepare model when enable tokenization flag in some ops (#99) --- data_juicer/utils/model_utils.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/data_juicer/utils/model_utils.py b/data_juicer/utils/model_utils.py index 5b242232a..db5fff4e6 100644 --- a/data_juicer/utils/model_utils.py +++ b/data_juicer/utils/model_utils.py @@ -269,6 +269,4 @@ def get_model(model_key, lang='en', model_type='sentencepiece'): :param model_key: name of the model or tokenzier """ - if model_key not in MODEL_ZOO: - prepare_model(lang=lang, model_type=model_type, model_key=model_key) return MODEL_ZOO.get(model_key, None)