Skip to content

Commit

Permalink
Update core.py
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaowuhu committed Jul 9, 2024
1 parent c5ea84a commit 931059f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion onnxscript/function_libs/torch_lib/ops/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -6583,10 +6583,11 @@ def aten_prelu_backward(
raise NotImplementedError()


@torch_op(("aten::prod", "aten::prod.dim_int"), trace_only=True)
@torch_op(("aten::prod.dim_int"), trace_only=True)
def aten_prod(self: TReal, dim: int, keepdim: bool = False) -> TReal:
"""prod(Tensor self, *, ScalarType? dtype=None) -> Tensor"""

# Todo: add test for this function later
return op.ReduceProd(self, axes=[dim], keepdims=keepdim)

Check warning on line 6591 in onnxscript/function_libs/torch_lib/ops/core.py

View check run for this annotation

Codecov / codecov/patch

onnxscript/function_libs/torch_lib/ops/core.py#L6591

Added line #L6591 was not covered by tests


Expand Down

0 comments on commit 931059f

Please sign in to comment.