onnx fmod uses fmod (#16018)

This commit is contained in:
chenyu
2026-05-01 16:47:11 -04:00
committed by GitHub
parent 782d1ff80f
commit 0bffbc5f8a
+1 -1
View File
@@ -644,7 +644,7 @@ def get_onnx_ops() -> dict[str, types.FunctionType|dict[OpSetId, types.FunctionT
def BitwiseOr(x:Tensor,y:Tensor): return x | y
def BitwiseXor(x:Tensor,y:Tensor): return x ^ y
def BitwiseNot(x:Tensor): return ~x
def Mod(x:Tensor,y:Tensor,fmod=0): return x - x.div(y, rounding_mode="trunc") * y if fmod else x % y
def Mod(x:Tensor,y:Tensor,fmod=0): return x.fmod(y) if fmod else x % y
# ***** Casting Ops *****
# NOTE: saturate only applies to FP8 types