| { |
| "op": "ai.onnx.BlackmanWindow", |
| "cases": [ |
| { |
| "name": "periodic_f32_size16", |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [16] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [16], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "symmetric_f32_size16", |
| "attrs": { "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [16] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [16], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "periodic_f32_size10", |
| "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_blackmanwindow" }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [10] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [10], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "symmetric_f32_size10_onnx_backend", |
| "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_blackmanwindow_symmetric" }, |
| "attrs": { "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [10] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [10], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "periodic_f32_size0_empty", |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [0] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [0], "tolerance": 0 } } |
| }, |
| { |
| "name": "periodic_f32_size1_boundary", |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [1] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [1], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "symmetric_f32_size1_nan_boundary", |
| "provenance": { |
| "source": "onnxruntime/test/providers/cpu/signal/signal_ops_test.cc", |
| "test": "SignalOpsTest.BlackmanWindowFloat", |
| "notes": "Additional ORT-validated edge: symmetric size 1 uses denominator length - 1 = 0 and produces NaN." |
| }, |
| "attrs": { "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [1] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "float32", |
| "shape": [1], |
| "tolerance": 0, |
| "allowNaN": true, |
| "data": { "kind": "values", "values": ["NaN"] } |
| } |
| } |
| }, |
| { |
| "name": "symmetric_f32_odd_size7", |
| "attrs": { "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [7] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [7], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "periodic_f16_size32", |
| "attrs": { "output_datatype": 10 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [32] } } }, |
| "outputs": { "y": { "dtype": "float16", "shape": [32], "tolerance": 0.002 } } |
| }, |
| { |
| "name": "ort_periodic_uint8_output_size8", |
| "provenance": { |
| "source": "ONNX Runtime CPUExecutionProvider", |
| "notes": "ONNX BlackmanWindow computes in float and applies output_datatype=UINT8 as a final cast." |
| }, |
| "attrs": { "output_datatype": 2 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [8] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "uint8", |
| "shape": [8], |
| "tolerance": 0, |
| "data": { "kind": "values", "values": [0, 0, 0, 0, 1, 0, 0, 0] } |
| } |
| } |
| }, |
| { |
| "name": "ort_symmetric_int8_output_size1_zero_cast", |
| "provenance": { |
| "source": "ONNX Runtime CPUExecutionProvider", |
| "notes": "The symmetric size-one formula produces NaN in float; ONNX Cast to INT8 maps that value to zero." |
| }, |
| "attrs": { "output_datatype": 3, "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [1] } } }, |
| "outputs": { "y": { "dtype": "int8", "shape": [1], "tolerance": 0, "data": { "kind": "values", "values": [0] } } } |
| }, |
| { |
| "name": "onnx_standard_periodic_int16_output_size8", |
| "attrs": { "output_datatype": 5 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [8] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "int16", |
| "shape": [8], |
| "tolerance": 0, |
| "data": { "kind": "values", "values": [0, 0, 0, 0, 1, 0, 0, 0] } |
| } |
| } |
| }, |
| { |
| "name": "onnx_standard_periodic_int32_output_size8", |
| "attrs": { "output_datatype": 6 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [8] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "int32", |
| "shape": [8], |
| "tolerance": 0, |
| "data": { "kind": "values", "values": [0, 0, 0, 0, 1, 0, 0, 0] } |
| } |
| } |
| }, |
| { |
| "name": "onnx_standard_periodic_uint32_output_size8", |
| "attrs": { "output_datatype": 12 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [8] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "uint32", |
| "shape": [8], |
| "tolerance": 0, |
| "data": { "kind": "values", "values": [0, 0, 0, 0, 1, 0, 0, 0] } |
| } |
| } |
| }, |
| { |
| "name": "periodic_f16_size1024_edge_sibling", |
| "provenance": { |
| "notes": "Compact f16 sibling for the 1M BlackmanWindow benchmark; preserves the f16 periodic generic window path without benchmark-scale output." |
| }, |
| "attrs": { "output_datatype": 10 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [1024] } } }, |
| "outputs": { "y": { "dtype": "float16", "shape": [1024], "tolerance": 0.002 } } |
| }, |
| { |
| "name": "periodic_f32_size257_phase_accuracy_gpu_gap", |
| "skipGpu": { |
| "category": "todo", |
| "reason": "The current f32 cosine and range-reduction path crosses the final rounding boundary for this periodic size-257 window. A correctly rounded approximation or software-extended precision could close this implementable gap." |
| }, |
| "provenance": { |
| "source": "onnxruntime/test/providers/cpu/signal/signal_ops_test.cc", |
| "test": "SignalOpsTest.BlackmanWindowFloat", |
| "notes": "Medium odd-sized periodic window stresses f32 phase formation and the three-term cosine-sum path; CPU and ORT agree more tightly than the current WGSL f32 implementation." |
| }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [257] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [257], "tolerance": 6e-8, "relTolerance": 0 } } |
| }, |
| { |
| "name": "symmetric_f32_size257_phase_accuracy_gpu_gap", |
| "skipGpu": { |
| "category": "todo", |
| "reason": "The current f32 cosine and range-reduction path crosses the final rounding boundary for this symmetric size-257 window. A correctly rounded approximation or software-extended precision could close this implementable gap." |
| }, |
| "provenance": { |
| "source": "onnxruntime/test/providers/cpu/signal/signal_ops_test.cc", |
| "test": "SignalOpsTest.BlackmanWindowFloat", |
| "notes": "Symmetric odd-sized companion to the periodic phase edge; the length-1 denominator shifts every non-cardinal cosine sample and exposes f32 phase drift in the WGSL three-term cosine path." |
| }, |
| "attrs": { "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [257] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [257], "tolerance": 6e-8, "relTolerance": 0 } } |
| }, |
| { |
| "name": "ort_periodic_f32_size32", |
| "provenance": { |
| "source": "onnxruntime/test/providers/cpu/signal/signal_ops_test.cc", |
| "test": "SignalOpsTest.BlackmanWindowFloat" |
| }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [32] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "float32", |
| "shape": [32], |
| "tolerance": 0.00001, |
| "data": { |
| "kind": "values", |
| "values": [0.0, 0.003518, 0.014629, 0.03488, 0.066447, 0.1116, 0.17209, 0.248544, 0.34, 0.443635, 0.554773, 0.66717, 0.773553, 0.86635, 0.938508, 0.984303, 1.0, 0.984303, 0.938508, 0.86635, 0.773553, 0.66717, 0.554773, 0.443635, 0.34, 0.248544, 0.17209, 0.1116, 0.066447, 0.03488, 0.014629, 0.003518] |
| } |
| } |
| } |
| }, |
| { |
| "name": "periodic_int32_size8", |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [8] } } }, |
| "outputs": { "y": { "dtype": "float32", "shape": [8], "tolerance": 0.00001 } } |
| }, |
| { |
| "name": "symmetric_f32_size2_denom1", |
| "attrs": { "periodic": 0 }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [2] } } }, |
| "outputs": { |
| "y": { |
| "dtype": "float32", |
| "shape": [2], |
| "tolerance": 0.00001, |
| "data": { "kind": "values", "values": [0.0, 0.0] } |
| } |
| } |
| }, |
| { |
| "name": "symmetric_f16_size16", |
| "attrs": { "output_datatype": 10, "periodic": 0 }, |
| "requires": { "features": ["shader-f16"] }, |
| "inputs": { "size": { "dtype": "int32", "shape": [], "data": { "kind": "values", "values": [16] } } }, |
| "outputs": { "y": { "dtype": "float16", "shape": [16], "tolerance": 0.002 } } |
| } |
| ] |
| } |
|
|