From a1c847e3aef462c1142842665b8fe066447f1ab4 Mon Sep 17 00:00:00 2001 From: intellinjun Date: Wed, 3 Jul 2024 14:03:07 +0800 Subject: [PATCH] update ipex api Signed-off-by: intellinjun --- .../neural_chat/models/model_utils.py | 9 --------- 1 file changed, 9 deletions(-) diff --git a/intel_extension_for_transformers/neural_chat/models/model_utils.py b/intel_extension_for_transformers/neural_chat/models/model_utils.py index 2207eebf4bd..2e676101a18 100644 --- a/intel_extension_for_transformers/neural_chat/models/model_utils.py +++ b/intel_extension_for_transformers/neural_chat/models/model_utils.py @@ -845,15 +845,6 @@ def load_model( dtype=torch_dtype, inplace=True, ) - except AssertionError: - model = intel_ipex.optimize( - model.eval(), - dtype=torch_dtype, - inplace=True, - level="O1", - auto_kernel_selection=True, - weights_prepack=False, - ) except Exception as e: logging.info(f"IPEX optimize failure! Skip IPEX.") model = model.eval()