Download build/webgpu/test.json from webgpu-kernels/ai.onnx.IsNaN: direct link, hf CLI and curl.
- Browser
- Download file 7.1 kB
-
https://huggingface.co/kernels/webgpu-kernels/ai.onnx.IsNaN/resolve/v1/build/webgpu/test.json
- Command line
-
hf download hf://webgpu-kernels/ai.onnx.IsNaN@v1/build/webgpu/test.json
-
curl -L -o test.json https://huggingface.co/kernels/webgpu-kernels/ai.onnx.IsNaN/resolve/v1/build/webgpu/test.json
7.1 kB
| { | |
| "cases": [ | |
| { | |
| "name": "f32_nan_inf_finite", | |
| "inputs": { | |
| "x": { | |
| "dtype": "float32", | |
| "shape": [2, 4], | |
| "data": { "kind": "values", "values": [1.0, "NaN", "Infinity", "-Infinity", 0.0, "NaN", -5.5, 3.25] } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [2, 4] } } | |
| }, | |
| { | |
| "name": "f16_nan_values", | |
| "inputs": { | |
| "x": { | |
| "dtype": "float16", | |
| "shape": [2, 3], | |
| "data": { "kind": "values", "values": ["NaN", 0.0, 1.0, -2.0, "NaN", "Infinity"] } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [2, 3] } } | |
| }, | |
| { | |
| "name": "scalar_false", | |
| "inputs": { "x": { "dtype": "float32", "shape": [], "data": { "kind": "values", "values": [42.0] } } }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [] } } | |
| }, | |
| { | |
| "name": "scalar_true", | |
| "inputs": { "x": { "dtype": "float32", "shape": [], "data": { "kind": "values", "values": ["NaN"] } } }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "zero_size_noop", | |
| "inputs": { "x": { "dtype": "float16", "shape": [0, 3], "data": { "kind": "values", "values": [] } } }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [0, 3], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "ort_float_opset20_2x2", | |
| "provenance": { | |
| "source": "onnxruntime/test/providers/cpu/tensor/isnan_test.cc", | |
| "test": "IsNaNOpTest.IsNaNFloat20" | |
| }, | |
| "inputs": { | |
| "x": { "dtype": "float32", "shape": [2, 2], "data": { "kind": "values", "values": [1.0, "NaN", 2.0, "NaN"] } } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [2, 2], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "onnx_backend_float_specials", | |
| "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_isnan", "test": "test_isnan" }, | |
| "inputs": { | |
| "x": { | |
| "dtype": "float32", | |
| "shape": [6], | |
| "data": { "kind": "values", "values": [-1.2, "NaN", "Infinity", 2.8, "-Infinity", "Infinity"] } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [6], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "ort_float16_opset20_2x2", | |
| "provenance": { | |
| "source": "onnxruntime/test/providers/cpu/tensor/isnan_test.cc", | |
| "test": "IsNaNOpTest.IsNaNFloat16_20" | |
| }, | |
| "inputs": { | |
| "x": { "dtype": "float16", "shape": [2, 2], "data": { "kind": "values", "values": [1.0, "NaN", 2.0, "NaN"] } } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [2, 2], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "onnx_backend_float16_specials", | |
| "provenance": { | |
| "source": "cmake/external/onnx/onnx/backend/test/data/node/test_isnan_float16", | |
| "test": "test_isnan_float16" | |
| }, | |
| "inputs": { | |
| "x": { | |
| "dtype": "float16", | |
| "shape": [6], | |
| "data": { "kind": "values", "values": [-1.2, "NaN", "Infinity", 2.8, "-Infinity", "Infinity"] } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [6], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "onnx_backend_isnan", | |
| "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_isnan" }, | |
| "inputs": { | |
| "x": { | |
| "dtype": "float32", | |
| "shape": [6], | |
| "data": { | |
| "kind": "values", | |
| "values": [-1.2000000476837158, "NaN", "Infinity", 2.799999952316284, "-Infinity", "Infinity"] | |
| } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [6], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "onnx_backend_isnan_float16", | |
| "provenance": { "source": "cmake/external/onnx/onnx/backend/test/data/node/test_isnan_float16" }, | |
| "inputs": { | |
| "x": { | |
| "dtype": "float16", | |
| "shape": [6], | |
| "data": { | |
| "kind": "values", | |
| "values": [-1.2001953125, "NaN", "Infinity", 2.80078125, "-Infinity", "Infinity"] | |
| } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [6], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "ort_bool_exact_empty_float16_zero_dim", | |
| "provenance": { | |
| "source": "onnxruntime/test/providers/cpu/tensor/isnan_test.cc", | |
| "test": "IsNaNOpTest.IsNaNFloat16_20", | |
| "notes": "Zero-dimension projection of ORT's float16 IsNaN coverage." | |
| }, | |
| "inputs": { "x": { "dtype": "float16", "shape": [0, 2], "data": { "kind": "values", "values": [] } } }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [0, 2], "tolerance": 0 } } | |
| }, | |
| { | |
| "name": "f32_vec4_mixed_nan_16", | |
| "provenance": { | |
| "notes": "A compact aligned float32 input exercises mixed NaN, Infinity, and finite lanes on the same-layout vectorized path." | |
| }, | |
| "inputs": { | |
| "x": { | |
| "dtype": "float32", | |
| "shape": [16], | |
| "data": { | |
| "kind": "values", | |
| "values": ["NaN", 0.0, "Infinity", "-Infinity", 1.5, "NaN", -2.0, 3.0, 4.0, 5.0, "NaN", 6.0, "-Infinity", 7.0, 8.0, "NaN"] | |
| } | |
| } | |
| }, | |
| "outputs": { | |
| "y": { | |
| "dtype": "bool", | |
| "shape": [16], | |
| "tolerance": 0, | |
| "data": { "kind": "values", "values": [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1] } | |
| } | |
| } | |
| }, | |
| { | |
| "name": "f16_all_nan_vec4", | |
| "inputs": { | |
| "x": { "dtype": "float16", "shape": [4], "data": { "kind": "values", "values": ["NaN", "NaN", "NaN", "NaN"] } } | |
| }, | |
| "outputs": { | |
| "y": { "dtype": "bool", "shape": [4], "tolerance": 0, "data": { "kind": "values", "values": [1, 1, 1, 1] } } | |
| } | |
| }, | |
| { | |
| "name": "f16_mixed_nan_non_nan_vec4", | |
| "inputs": { | |
| "x": { "dtype": "float16", "shape": [4], "data": { "kind": "values", "values": ["NaN", 1.0, -1.0, "NaN"] } } | |
| }, | |
| "outputs": { | |
| "y": { "dtype": "bool", "shape": [4], "tolerance": 0, "data": { "kind": "values", "values": [1, 0, 0, 1] } } | |
| } | |
| }, | |
| { | |
| "name": "rank7_vec4", | |
| "inputs": { | |
| "x": { | |
| "dtype": "float32", | |
| "shape": [1, 1, 1, 1, 1, 1, 8], | |
| "data": { "kind": "values", "values": ["NaN", 1.0, "Infinity", "-Infinity", 0.0, "NaN", 2.0, "NaN"] } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [1, 1, 1, 1, 1, 1, 8], "tolerance": 0 } }, | |
| "provenance": { | |
| "notes": "A rank-7 flat input exercises the shared vec4 unary path, whose indexing depends only on total element count." | |
| } | |
| }, | |
| { | |
| "name": "rank7_scalar", | |
| "inputs": { | |
| "x": { | |
| "dtype": "float32", | |
| "shape": [1, 1, 1, 1, 1, 1, 3], | |
| "data": { "kind": "values", "values": ["NaN", 1.0, "NaN"] } | |
| } | |
| }, | |
| "outputs": { "y": { "dtype": "bool", "shape": [1, 1, 1, 1, 1, 1, 3], "tolerance": 0 } }, | |
| "provenance": { | |
| "notes": "A rank-seven input with three values checks IsNaN on a high-rank shape whose element count is not a multiple of four." | |
| } | |
| } | |
| ] | |
| } | |