Skip to content

Commit

Permalink
bool
Browse files Browse the repository at this point in the history
  • Loading branch information
justinchuby committed Jan 3, 2025
1 parent 04ca4b5 commit 75a355d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion onnxscript/optimizer/_constant_folding.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ def _get_bool_value(val: ir.Value | None) -> bool | None:
value = _get_numpy_value(val)
if value is None:
return None
if value.size == 1 and value.dtype is bool:
if value.size == 1 and value.dtype == np.bool_:
return value.item(0)
return None

Expand Down

0 comments on commit 75a355d

Please sign in to comment.