Skip to content

Commit ef16a2f

Browse files
committed
mypy
1 parent d02d748 commit ef16a2f

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

onnx_diagnostic/helpers/log_helper.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -579,7 +579,7 @@ def view(
579579
)
580580
piv = data.pivot(index=key_index[::-1], columns=key_columns, values=values)
581581
if isinstance(piv, pandas.Series):
582-
piv = piv.to_frame(name="serie")
582+
piv = piv.to_frame(name="series")
583583
if view_def.transpose:
584584
piv = piv.T
585585
return (piv, view_def) if return_view_def else piv
@@ -592,15 +592,17 @@ def _dropna(
592592
values: Sequence[str],
593593
keep_columns_in_index: Optional[Sequence[str]] = None,
594594
) -> Tuple[pandas.DataFrame, Sequence[str], Sequence[str], Sequence[str]]:
595-
keep_columns_in_index = set(keep_columns_in_index) if keep_columns_in_index else set()
595+
set_keep_columns_in_index = (
596+
set(keep_columns_in_index) if keep_columns_in_index else set()
597+
)
596598
v = data[values]
597599
new_data = data[~v.isnull().all(1)]
598600
if data.shape == new_data.shape:
599601
return data, key_index, key_columns, values
600602
new_data = new_data.copy()
601603
new_key_index = []
602604
for c in key_index:
603-
if c in keep_columns_in_index:
605+
if c in set_keep_columns_in_index:
604606
new_key_index.append(c)
605607
continue
606608
v = new_data[c]
@@ -609,7 +611,7 @@ def _dropna(
609611
new_key_index.append(c)
610612
new_key_columns = []
611613
for c in key_columns:
612-
if c in keep_columns_in_index:
614+
if c in set_keep_columns_in_index:
613615
new_key_columns.append(c)
614616
continue
615617
v = new_data[c]

0 commit comments

Comments
 (0)