Skip to content

Commit 7148ebd

Browse files
committed
fix issues
1 parent 46b9337 commit 7148ebd

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

_unittests/ut_export/test_dynamic_shapes.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -845,6 +845,7 @@ def test_dynamic_cache_replace_by_string(self):
845845
as_string,
846846
)
847847

848+
@requires_transformers("4.51")
848849
def test_unbatch_inputs(self):
849850
data = get_untrained_model_with_inputs("arnir0/Tiny-LLM")
850851
cpl = CoupleInputsDynamicShapes(

onnx_diagnostic/helpers/model_builder_helper.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,9 @@ def save_model_builder(self, out_dir: Optional[str] = "", verbose: int = 0) -> M
181181
location = os.path.basename(data_path)
182182
if os.path.exists(location):
183183
os.remove(location)
184+
if verbose:
185+
print(f"[save_model_builder] out_path={out_path!r}")
186+
print(f"[save_model_builder] location={location!r}")
184187
save_model(
185188
model,
186189
out_path,

onnx_diagnostic/torch_models/test_helper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ def validate_model(
356356
print(f"[validate_model] set batch=1 for data[{k!r}]")
357357
print(f"[validate_model] batch=1 === {string_type(data[k], with_shape=True)}")
358358
cpl = CoupleInputsDynamicShapes(
359-
None, data[k], dynamic_shapes=data["dynamic_shapes"]
359+
tuple(), data[k], dynamic_shapes=data["dynamic_shapes"]
360360
)
361361
data[k] = cpl.change_dynamic_dimensions(
362362
desired_values=dict(batch=1), only_desired=True

0 commit comments

Comments
 (0)