File tree 2 files changed +3
-3
lines changed
optimum/intel/neural_compressor
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 30
30
- name : Install dependencies
31
31
run : |
32
32
python -m pip install --upgrade pip
33
- pip install cmake>=3.16
33
+ pip install cmake
34
34
pip install py-cpuinfo
35
35
pip install torch==2.1.0 torchaudio==2.1.0 torchvision==0.16 --extra-index-url https://download.pytorch.org/whl/cpu
36
36
pip install .[neural-compressor,diffusers,tests]
Original file line number Diff line number Diff line change @@ -214,7 +214,7 @@ def quantize(
214
214
215
215
if quantization_config is None :
216
216
quantization_config = WeightOnlyQuantConfig ()
217
- algo = [ "RTN" ]
217
+ algo = "RTN"
218
218
elif isinstance (quantization_config , WeightOnlyQuantConfig ):
219
219
algo = quantization_config .algorithm
220
220
else :
@@ -223,7 +223,7 @@ def quantize(
223
223
)
224
224
225
225
if algo not in ["RTN" , "GPTQ" ]:
226
- raise ValueError ("Weight-only quantization is only support RTN and GPTQ algorithm now!" )
226
+ raise ValueError (f "Weight-only quantization is only support RTN and GPTQ algorithm now!But got { algo } " )
227
227
228
228
if calibration_dataset is None and quantization_config .tokenizer is None and ("GPTQ" in algo ):
229
229
raise ValueError (
You can’t perform that action at this time.
0 commit comments