{ "op": "ai.onnx.Or", "cases": [ { "name": "same_shape_vec4_nonzero", "inputs": { "a": { "dtype": "bool", "shape": [8], "data": { "kind": "values", "values": [0, 1, 1, 1, 0, 1, 1, 0] } }, "b": { "dtype": "bool", "shape": [8], "data": { "kind": "values", "values": [0, 0, 1, 0, 1, 1, 0, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [8], "tolerance": 0, "data": { "kind": "values", "values": [0, 1, 1, 1, 1, 1, 1, 1] } } } }, { "name": "broadcast", "inputs": { "a": { "dtype": "bool", "shape": [2, 3], "data": { "kind": "values", "values": [0, 1, 1, 0, 1, 0] } }, "b": { "dtype": "bool", "shape": [3], "data": { "kind": "values", "values": [1, 0, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [2, 3] } } }, { "name": "rank0_zero_or_nonzero_scalar_output", "inputs": { "a": { "dtype": "bool", "shape": [], "data": { "kind": "values", "values": [0] } }, "b": { "dtype": "bool", "shape": [], "data": { "kind": "values", "values": [1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [], "tolerance": 0 } } }, { "name": "rank_mismatch_broadcast", "inputs": { "a": { "dtype": "bool", "shape": [2, 1, 3], "data": { "kind": "values", "values": [0, 0, 1, 0, 1, 0] } }, "b": { "dtype": "bool", "shape": [3], "data": { "kind": "values", "values": [1, 0, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [2, 1, 3], "tolerance": 0 } } }, { "name": "zero_sized_broadcast", "inputs": { "a": { "dtype": "bool", "shape": [2, 0, 3], "data": { "kind": "values", "values": [] } }, "b": { "dtype": "bool", "shape": [3], "data": { "kind": "values", "values": [0, 0, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [2, 0, 3], "tolerance": 0 } } }, { "name": "ort_bool_vector", "provenance": { "source": "onnxruntime/test/providers/cpu/math/element_wise_ops_test.cc", "test": "MathOpTest.Or" }, "inputs": { "a": { "dtype": "bool", "shape": [4], "data": { "kind": "values", "values": [0, 1, 0, 1] } }, "b": { "dtype": "bool", "shape": [4], "data": { "kind": "values", "values": [0, 0, 1, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [4], "tolerance": 0 } } }, { "name": "onnx_backend_2d_bool", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or2d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4], "data": { "kind": "values", "values": [1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1] } }, "b": { "dtype": "bool", "shape": [3, 4], "data": { "kind": "values", "values": [1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4], "tolerance": 0 } } }, { "name": "onnx_backend_bcast3v2d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or_bcast3v2d", "test": "test_or_bcast3v2d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4, 5], "data": { "kind": "values", "values": [0, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 0] } }, "b": { "dtype": "bool", "shape": [4, 5], "data": { "kind": "values", "values": [0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5], "tolerance": 0 } } }, { "name": "onnx_backend_or_bcast3v1d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or_bcast3v1d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4, 5], "data": { "kind": "values", "values": [1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0] } }, "b": { "dtype": "bool", "shape": [5], "data": { "kind": "values", "values": [0, 0, 0, 0, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5], "tolerance": 0 } } }, { "name": "onnx_backend_or4d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or4d", "test": "test_or4d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4, 5, 6], "data": { "kind": "values", "values": [1, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1,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 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5, 6], "tolerance": 0 } } }, { "name": "onnx_backend_or_bcast4v2d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or_bcast4v2d", "test": "test_or_bcast4v2d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4, 5, 6], "data": { "kind": "values", "values": [1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0] } }, "b": { "dtype": "bool", "shape": [5, 6], "data": { "kind": "values", "values": [0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 1, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5, 6], "tolerance": 0 } } }, { "name": "onnx_backend_or_bcast4v3d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or_bcast4v3d", "test": "test_or_bcast4v3d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4, 5, 6], "data": { "kind": "values", "values": [0, 0, 0, 0, 0, 1, 0, 0, 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, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0] } }, "b": { "dtype": "bool", "shape": [4, 5, 6], "data": { "kind": "values", "values": [1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 0, 1, 0, 1, 1, 1, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5, 6], "tolerance": 0 } } }, { "name": "onnx_backend_or_bcast4v4d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or_bcast4v4d", "test": "test_or_bcast4v4d" }, "inputs": { "a": { "dtype": "bool", "shape": [1, 4, 1, 6], "data": { "kind": "values", "values": [0, 1, 0, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 1] } }, "b": { "dtype": "bool", "shape": [3, 1, 5, 6], "data": { "kind": "values", "values": [0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5, 6], "tolerance": 0 } } }, { "name": "onnx_backend_or3d", "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_or3d" }, "inputs": { "a": { "dtype": "bool", "shape": [3, 4, 5], "data": { "kind": "values", "values": [1, 0, 1, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0] } }, "b": { "dtype": "bool", "shape": [3, 4, 5], "data": { "kind": "values", "values": [1, 1, 1, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [3, 4, 5], "tolerance": 0 } } }, { "name": "ort_bool_exact_bcast3v2d", "provenance": { "source": "onnxruntime/test/providers/cpu/math/element_wise_ops_test.cc", "test": "MathOpTest.Xor_bcast3v2d", "notes": "Uses ORT's bool 3D-vs-2D broadcast geometry with Or's truth table." }, "inputs": { "a": { "dtype": "bool", "shape": [2, 3, 4], "data": { "kind": "values", "values": [0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1] } }, "b": { "dtype": "bool", "shape": [3, 4], "data": { "kind": "values", "values": [0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [2, 3, 4], "data": { "kind": "values", "values": [0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1] }, "tolerance": 0 } } }, { "name": "same_shape_numel_not_div4", "inputs": { "a": { "dtype": "bool", "shape": [9], "data": { "kind": "values", "values": [0, 1, 1, 0, 1, 0, 1, 1, 0] } }, "b": { "dtype": "bool", "shape": [9], "data": { "kind": "values", "values": [0, 0, 1, 1, 0, 1, 0, 1, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [9], "tolerance": 0 } } }, { "name": "scalar_broadcast_to_vector", "inputs": { "a": { "dtype": "bool", "shape": [], "data": { "kind": "values", "values": [1] } }, "b": { "dtype": "bool", "shape": [6], "data": { "kind": "values", "values": [0, 1, 0, 1, 0, 1] } } }, "outputs": { "c": { "dtype": "bool", "shape": [6], "tolerance": 0 } } }, { "name": "rank7_broadcast", "inputs": { "a": { "dtype": "bool", "shape": [2, 1, 2, 1, 2, 1, 2], "data": { "kind": "cycle", "values": [0, 1, 0, 1, 0, 0, 1, 1] } }, "b": { "dtype": "bool", "shape": [1, 2, 1, 2, 1, 2, 1], "data": { "kind": "cycle", "values": [1, 0, 1, 0, 1, 1, 0, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [2, 2, 2, 2, 2, 2, 2], "tolerance": 0 } } }, { "name": "bool_cross_broadcast_16x257_perf_compact", "provenance": { "notes": "Compact sibling for the 2D Or broadcast benchmark; [1, cols] by [rows, 1] preserves cross-broadcast address arithmetic with an unaligned inner extent." }, "inputs": { "a": { "dtype": "bool", "shape": [1, 257], "data": { "kind": "cycle", "values": [0, 1, 0, 1] } }, "b": { "dtype": "bool", "shape": [16, 1], "data": { "kind": "cycle", "values": [1, 0, 1, 0] } } }, "outputs": { "c": { "dtype": "bool", "shape": [16, 257], "tolerance": 0 } } } ] }