File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -203,7 +203,7 @@ def parse_args(parser: "ArgumentParser"):
203
203
return parse_args_openvino (parser )
204
204
205
205
def run (self ):
206
- from ...exporters .openvino .__main__ import main_export , infer_task
206
+ from ...exporters .openvino .__main__ import infer_task , main_export
207
207
from ...intel .openvino .configuration import _DEFAULT_4BIT_CONFIGS , OVConfig
208
208
209
209
if self .args .fp16 :
@@ -321,10 +321,10 @@ def run(self):
321
321
export_tokenizer (tokenizer_2 , output / "tokenizer_2" )
322
322
else :
323
323
task = infer_task (self .args .task , self .args .model )
324
- quantization_config = ov_config .quantization_config
324
+ quantization_config = ov_config .quantization_config if ov_config else None
325
325
quantize_after_export = (
326
326
task .startswith ("text-generation" )
327
- and quantization_config is not None
327
+ and quantization_config
328
328
and hasattr (quantization_config , "dataset" )
329
329
and quantization_config .dataset is not None
330
330
)
You can’t perform that action at this time.
0 commit comments