Skip to content

Commit 8037d0c

Browse files
committed
fix bug
1 parent d677cf8 commit 8037d0c

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

CHANGELOGS.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ Change Logs
44
0.7.8
55
+++++
66

7+
* :pr:`210`: add utilities to investigate models
78
* :pr:`208`: add a patch for Qwen3 (rewrite a loop)
89

910
0.7.7

onnx_diagnostic/helpers/config_helper.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,13 @@ def build_diff_config(config0, config1):
138138
for k in config0:
139139
assert isinstance(k, str), f"k={k!r}, wrong type in {config0}"
140140
if k not in config1:
141-
diff[k] = f"-{config0[k]}"
141+
v0 = getattr(config0, k) if hasattr(config0, k) else config0[k]
142+
diff[k] = f"-{v0}"
142143
for k in config1:
143144
assert isinstance(k, str), f"k={k!r}, wrong type in {config1}"
144145
if k not in config0:
145-
diff[k] = f"+{config1[k]}"
146+
v1 = getattr(config1, k) if hasattr(config1, k) else config1[k]
147+
diff[k] = f"+{v1}"
146148
for k in config0:
147149
if k not in config1:
148150
continue

0 commit comments

Comments
 (0)