Skip to content

Commit

Permalink
Address mypy warning
Browse files Browse the repository at this point in the history
  • Loading branch information
gramalingam committed Dec 13, 2024
1 parent b64f222 commit 07c270a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions onnxscript/rewriter/onnxruntime/xformers/_test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@ def get_onnx_model(self):
model, inputs, input_names=input_names, dynamo=True, fallback=True
)
# ORT Transformer optimizations are applied after basic optimization.
onnxscript.optimizer.optimize(exported.model) # type: ignore[union-attr]
return exported.model
exported_model = exported.model # type: ignore[union-attr]
onnxscript.optimizer.optimize(exported_model)
return exported_model

Check warning on line 75 in onnxscript/rewriter/onnxruntime/xformers/_test_models.py

View check run for this annotation

Codecov / codecov/patch

onnxscript/rewriter/onnxruntime/xformers/_test_models.py#L73-L75

Added lines #L73 - L75 were not covered by tests

def get_inputs(self):
if not hasattr(self, "_inputs"):
Expand Down

0 comments on commit 07c270a

Please sign in to comment.