From 0e1788337c6e3c81f32e92cd21a5db5bf766f17d Mon Sep 17 00:00:00 2001 From: Ella Charlaix Date: Tue, 31 Oct 2023 17:05:03 +0100 Subject: [PATCH] fix --- optimum/intel/neural_compressor/quantization.py | 1 + optimum/intel/openvino/modeling_base.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/optimum/intel/neural_compressor/quantization.py b/optimum/intel/neural_compressor/quantization.py index 137b16b22d..bb232cdade 100644 --- a/optimum/intel/neural_compressor/quantization.py +++ b/optimum/intel/neural_compressor/quantization.py @@ -20,6 +20,7 @@ from pathlib import Path from typing import Callable, Dict, Optional, Union +import warnings import torch from datasets import Dataset, load_dataset from neural_compressor.adaptor.pytorch import PyTorch_FXAdaptor, _cfg_to_qconfig, _propagate_qconfig diff --git a/optimum/intel/openvino/modeling_base.py b/optimum/intel/openvino/modeling_base.py index 694c4e58c0..e8e62e0818 100644 --- a/optimum/intel/openvino/modeling_base.py +++ b/optimum/intel/openvino/modeling_base.py @@ -297,7 +297,7 @@ def _from_transformers( @classmethod def _to_load( cls, - model: "PreTrainedModel", + model, config: PretrainedConfig, onnx_config: OnnxConfig, use_auth_token: Optional[Union[bool, str]] = None,