Skip to content

Commit a220a36

Browse files
[Qwen3-TTS/ASR]update quantization comments of model conversion (#3414)
1 parent 25f4d2e commit a220a36

3 files changed

Lines changed: 12 additions & 8 deletions

File tree

notebooks/qwen3-asr/qwen3-asr.ipynb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@
236236
},
237237
{
238238
"cell_type": "code",
239-
"execution_count": 4,
239+
"execution_count": null,
240240
"id": "0c1a380f",
241241
"metadata": {},
242242
"outputs": [
@@ -251,6 +251,8 @@
251251
"source": [
252252
"from qwen_3_asr_helper import convert_qwen3_asr_model\n",
253253
"\n",
254+
"# from nncf import CompressWeightsMode\n",
255+
"\n",
254256
"model_id = model_selector.value\n",
255257
"model_name = model_id.split(\"/\")[-1]\n",
256258
"ov_model_dir = Path(f\"{model_name}-OV\")\n",
@@ -260,7 +262,7 @@
260262
"convert_qwen3_asr_model(\n",
261263
" model_id=model_id,\n",
262264
" output_dir=ov_model_dir,\n",
263-
" quantization_config=None, # Set to {\"mode\": \"INT8_SYM\"} for INT8 quantization\n",
265+
" quantization_config=None, # Set to {\"mode\": CompressWeightsMode.INT8_SYM} for INT8 quantization\n",
264266
")"
265267
]
266268
},

notebooks/qwen3-tts/qwen3-tts.ipynb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@
237237
},
238238
{
239239
"cell_type": "code",
240-
"execution_count": 11,
240+
"execution_count": null,
241241
"metadata": {},
242242
"outputs": [
243243
{
@@ -381,6 +381,8 @@
381381
"source": [
382382
"from qwen_3_tts_helper import convert_qwen3_tts_model\n",
383383
"\n",
384+
"# from nncf import CompressWeightsMode\n",
385+
"\n",
384386
"model_name = model_selector.value\n",
385387
"model_id = model_options[model_name]\n",
386388
"ov_model_dir = Path(f\"{model_name}-OV\")\n",
@@ -390,7 +392,7 @@
390392
"convert_qwen3_tts_model(\n",
391393
" model_id=model_id,\n",
392394
" output_dir=ov_model_dir,\n",
393-
" quantization_config=None, # Set to {\"mode\": \"INT8_SYM\"} for INT8 quantization\n",
395+
" quantization_config=None, # Set to {\"mode\": CompressWeightsMode.INT8_SYM} for INT8 quantization\n",
394396
")"
395397
]
396398
},

notebooks/qwen3-tts/qwen_3_tts_helper.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -866,10 +866,10 @@ def forward_wrap_code_predictor(
866866
patch_stateful(ov_model, 2)
867867
print("✅ Talker Code Predictor model successfully converted")
868868

869-
if quantization_config is not None:
870-
print(f"⌛ Weights compression with {quantization_config['mode']} mode started")
871-
ov_model = nncf.compress_weights(ov_model, **quantization_config)
872-
print("✅ Weights compression finished")
869+
# if quantization_config is not None:
870+
# print(f"⌛ Weights compression with {quantization_config['mode']} mode started")
871+
# ov_model = nncf.compress_weights(ov_model, **quantization_config)
872+
# print("✅ Weights compression finished")
873873

874874
ov.save_model(ov_model, talker_code_predictor_path)
875875
del ov_model

0 commit comments

Comments
 (0)