Skip to content

Commit

Permalink
nncf.quantize_with_accuracy_control fails with tune_hyperparams=True (o…
Browse files Browse the repository at this point in the history
…penvinotoolkit#2450)

Changes:

Minor fixes

Reason for changes:
nncf.quantize_with_accuracy_control fails with tune_hyperparams=True

Related tickets:
Ref: 131814

Tests:
Current tests
  • Loading branch information
andrey-churkin authored Feb 6, 2024
1 parent b49390e commit e3f7561
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion nncf/openvino/quantization/quantize_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ def native_quantize_with_accuracy_control_impl(
fast_bias_correction,
model_type,
ignored_scope,
advanced_quantization_parameters,
copied_parameters,
)
tuned_quantized_metric_results = evaluator.collect_metric_results(
tuned_quantized_model, validation_dataset, model_name="tuned"
Expand Down
3 changes: 2 additions & 1 deletion nncf/quantization/quantize_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,8 @@ def quantize_with_tune_hyperparams(
"advanced_parameters": advanced_quantization_parameters,
}

param_grids = get_quantization_param_grids(create_ptq_pipeline(**init_quantization_params))
backend = get_backend(model)
param_grids = get_quantization_param_grids(create_ptq_pipeline(**init_quantization_params), backend)

hyperparameter_tuner = HyperparameterTuner(
create_ptq_pipeline,
Expand Down

0 comments on commit e3f7561

Please sign in to comment.