Skip to content

Commit

Permalink
[torchlib] Improve aten::fill
Browse files Browse the repository at this point in the history
  • Loading branch information
justinchuby authored Jul 25, 2024
1 parent 712aa87 commit be86593
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions onnxscript/function_libs/torch_lib/ops/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -3622,10 +3622,6 @@ def aten_full(

if dtype != -1:
fill_value = op.Cast(fill_value, to=dtype)
if isinstance(size, list) and size == []:
# TODO(justinchuby): Handle empty list better than using isinstance
# size can be empty, meaning a scalar
return fill_value

size = op.Cast(size, to=INT64.dtype)
return op.Expand(fill_value, size)
Expand Down

0 comments on commit be86593

Please sign in to comment.