Skip to content

Commit c482582

Browse files
authoredFeb 7, 2025
1 parent 14c96db commit c482582

File tree

7 files changed

+9
-7
lines changed

7 files changed

+9
-7
lines changed
 

‎examples/tensorflow/common/object_detection/architecture/fpn.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -108,10 +108,11 @@ def __call__(self, multilevel_features, is_training=None):
108108

109109
input_levels = list(multilevel_features.keys())
110110
if min(input_levels) > self._min_level:
111-
raise ValueError(
111+
msg = (
112112
f"The minimum backbone level {min(input_levels)} should be "
113-
+ f"less or equal to FPN minimum level {self._min_level}."
113+
f"less or equal to FPN minimum level {self._min_level}."
114114
)
115+
raise ValueError(msg)
115116

116117
backbone_max_level = min(max(input_levels), self._max_level)
117118
with tf.name_scope("fpn"):

‎nncf/common/quantization/quantizer_setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ def select_qconfig(self, qconfig: QuantizerConfig) -> SingleConfigQuantizationPo
220220
qconfig_any = deepcopy(qconfig)
221221
qconfig_any.signedness_to_force = None
222222
if qconfig_any not in self.possible_qconfigs:
223-
msg = "Invalid selection for a quantizer config - " "tried to select {} among [{}]".format(
223+
msg = "Invalid selection for a quantizer config - tried to select {} among [{}]".format(
224224
qconfig, ",".join([str(q) for q in self.possible_qconfigs])
225225
)
226226
raise ValueError(msg)

‎nncf/quantization/algorithms/bias_correction/torch_fx_backend.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def get_output_name(model: torch.fx.GraphModule, node_name: str, output_port_id:
105105
elif node.op == "output":
106106
return node.all_input_nodes.index(graph_node)
107107

108-
msg = f"Node with name {node_name} expected to have an output," " no outputs were found."
108+
msg = f"Node with name {node_name} expected to have an output, no outputs were found."
109109
raise nncf.InternalError(msg)
110110

111111
@staticmethod

‎nncf/tensorflow/quantization/init_range.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def get_init_config_for_scope_and_group(self, node_name: str, group: QuantizerGr
7575
)
7676
)
7777
if len(matches) > 1:
78-
msg = f"Location {str(node_name)} matches more than one per-layer initialization parameter " "definition!"
78+
msg = f"Location {str(node_name)} matches more than one per-layer initialization parameter definition!"
7979
raise ValueError(msg)
8080
if len(matches) == 1:
8181
return matches[0]

‎nncf/torch/model_creation.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ def get_input_info_from_config(config: NNCFConfig) -> ModelInputInfo:
180180
return FillerInputInfo.from_nncf_config(config)
181181

182182
nncf_logger.debug(
183-
"Config has no 'input_info' section, trying to use dataloader output as model inputs " "for graph building."
183+
"Config has no 'input_info' section, trying to use dataloader output as model inputs for graph building."
184184
)
185185
exact_info = LoaderInputInfo.from_nncf_config_dataloaders(config)
186186
if exact_info is not None:

‎pyproject.toml

+1
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ select = [
142142
"UP", # pyupgrade
143143
"EM", # flake8-errmsg
144144
"INP", # flake8-no-pep420
145+
"ISC", # flake8-implicit-str-concat
145146
]
146147
extend-select = [
147148
"SIM", # https://pypi.org/project/flake8-simplify

‎tests/openvino/tools/calibrate.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@ def map_ignored_scope(ignored):
355355
if operations is not None:
356356
for op in operations:
357357
if op.get("attributes") is not None:
358-
msg = '"attributes" in the ignored operations ' "are not supported"
358+
msg = '"attributes" in the ignored operations are not supported'
359359
raise ValueError(msg)
360360
ignored_operations.append(op["type"])
361361
return {"ignored_scope": IgnoredScope(names=ignored.get("scope", []), types=ignored_operations)}

0 commit comments

Comments
 (0)