Skip to content

Commit

Permalink
Fix mp refinement procedure to run for target RUs (#1340)
Browse files Browse the repository at this point in the history
  • Loading branch information
ofirgo authored Jan 22, 2025
1 parent 109fdbe commit 33c45ff
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -189,9 +189,11 @@ def compute_resource_utilization_for_config(self, config: List[int]) -> Resource
"""
act_qcs, w_qcs = self.ru_helper.get_quantization_candidates(config)
act_qcs = None if (RUTarget.ACTIVATION not in self.ru_targets_to_compute and RUTarget.TOTAL not in self.ru_targets_to_compute) else act_qcs
w_qcs = None if (RUTarget.WEIGHTS not in self.ru_targets_to_compute and RUTarget.TOTAL not in self.ru_targets_to_compute) else w_qcs
ru = self.ru_helper.ru_calculator.compute_resource_utilization(
target_criterion=TargetInclusionCriterion.AnyQuantized, bitwidth_mode=BitwidthMode.QCustom, act_qcs=act_qcs,
w_qcs=w_qcs)
w_qcs=w_qcs, ru_targets=self.ru_targets_to_compute)
return ru

def finalize_distance_metric(self, layer_to_metrics_mapping: Dict[int, Dict[int, float]]):
Expand Down

0 comments on commit 33c45ff

Please sign in to comment.