summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/webnn/resources/test_data/transpose.json
diff options
context:
space:
mode:
Diffstat (limited to 'testing/web-platform/tests/webnn/resources/test_data/transpose.json')
-rw-r--r--testing/web-platform/tests/webnn/resources/test_data/transpose.json746
1 files changed, 746 insertions, 0 deletions
diff --git a/testing/web-platform/tests/webnn/resources/test_data/transpose.json b/testing/web-platform/tests/webnn/resources/test_data/transpose.json
new file mode 100644
index 0000000000..f7e6a7d2dd
--- /dev/null
+++ b/testing/web-platform/tests/webnn/resources/test_data/transpose.json
@@ -0,0 +1,746 @@
+{
+ "tests": [
+ {
+ "name": "transpose float32 1D constant tensor default options",
+ "inputs": {
+ "input": {
+ "shape": [24],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32",
+ "constant": true
+ }
+ },
+ "expected": {
+ "name": "output",
+ "shape": [24],
+ "data": [
+ -45.67443084716797,
+ 53.45924758911133,
+ -60.118492126464844,
+ 38.081748962402344,
+ 78.64247131347656,
+ -69.25324249267578,
+ 1.8434585332870483,
+ 92.8102798461914,
+ 56.100074768066406,
+ 77.05838012695312,
+ 57.46807861328125,
+ -84.74308776855469,
+ 46.38539123535156,
+ -84.89764404296875,
+ 56.70438766479492,
+ -25.695144653320312,
+ 5.62217378616333,
+ -25.66281509399414,
+ 99.46284484863281,
+ -87.58920288085938,
+ -65.3779067993164,
+ -66.00990295410156,
+ 38.466827392578125,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 1D tensor default options",
+ "inputs": {
+ "input": {
+ "shape": [24],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "expected": {
+ "name": "output",
+ "shape": [24],
+ "data": [
+ -45.67443084716797,
+ 53.45924758911133,
+ -60.118492126464844,
+ 38.081748962402344,
+ 78.64247131347656,
+ -69.25324249267578,
+ 1.8434585332870483,
+ 92.8102798461914,
+ 56.100074768066406,
+ 77.05838012695312,
+ 57.46807861328125,
+ -84.74308776855469,
+ 46.38539123535156,
+ -84.89764404296875,
+ 56.70438766479492,
+ -25.695144653320312,
+ 5.62217378616333,
+ -25.66281509399414,
+ 99.46284484863281,
+ -87.58920288085938,
+ -65.3779067993164,
+ -66.00990295410156,
+ 38.466827392578125,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 2D tensor default options",
+ "inputs": {
+ "input": {
+ "shape": [4, 6],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "expected": {
+ "name": "output",
+ "shape": [6, 4],
+ "data": [
+ -45.67443084716797,
+ 1.8434585332870483,
+ 46.38539123535156,
+ 99.46284484863281,
+ 53.45924758911133,
+ 92.8102798461914,
+ -84.89764404296875,
+ -87.58920288085938,
+ -60.118492126464844,
+ 56.100074768066406,
+ 56.70438766479492,
+ -65.3779067993164,
+ 38.081748962402344,
+ 77.05838012695312,
+ -25.695144653320312,
+ -66.00990295410156,
+ 78.64247131347656,
+ 57.46807861328125,
+ 5.62217378616333,
+ 38.466827392578125,
+ -69.25324249267578,
+ -84.74308776855469,
+ -25.66281509399414,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 3D tensor default options",
+ "inputs": {
+ "input": {
+ "shape": [2, 3, 4],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "expected": {
+ "name": "output",
+ "shape": [4, 3, 2],
+ "data": [
+ -45.67443084716797,
+ 46.38539123535156,
+ 78.64247131347656,
+ 5.62217378616333,
+ 56.100074768066406,
+ -65.3779067993164,
+ 53.45924758911133,
+ -84.89764404296875,
+ -69.25324249267578,
+ -25.66281509399414,
+ 77.05838012695312,
+ -66.00990295410156,
+ -60.118492126464844,
+ 56.70438766479492,
+ 1.8434585332870483,
+ 99.46284484863281,
+ 57.46807861328125,
+ 38.466827392578125,
+ 38.081748962402344,
+ -25.695144653320312,
+ 92.8102798461914,
+ -87.58920288085938,
+ -84.74308776855469,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 4D tensor default options",
+ "inputs": {
+ "input": {
+ "shape": [1, 2, 3, 4],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "expected": {
+ "name": "output",
+ "shape": [4, 3, 2, 1],
+ "data": [
+ -45.67443084716797,
+ 46.38539123535156,
+ 78.64247131347656,
+ 5.62217378616333,
+ 56.100074768066406,
+ -65.3779067993164,
+ 53.45924758911133,
+ -84.89764404296875,
+ -69.25324249267578,
+ -25.66281509399414,
+ 77.05838012695312,
+ -66.00990295410156,
+ -60.118492126464844,
+ 56.70438766479492,
+ 1.8434585332870483,
+ 99.46284484863281,
+ 57.46807861328125,
+ 38.466827392578125,
+ 38.081748962402344,
+ -25.695144653320312,
+ 92.8102798461914,
+ -87.58920288085938,
+ -84.74308776855469,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 5D tensor default options",
+ "inputs": {
+ "input": {
+ "shape": [1, 2, 1, 3, 4],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "expected": {
+ "name": "output",
+ "shape": [4, 3, 1, 2, 1],
+ "data": [
+ -45.67443084716797,
+ 46.38539123535156,
+ 78.64247131347656,
+ 5.62217378616333,
+ 56.100074768066406,
+ -65.3779067993164,
+ 53.45924758911133,
+ -84.89764404296875,
+ -69.25324249267578,
+ -25.66281509399414,
+ 77.05838012695312,
+ -66.00990295410156,
+ -60.118492126464844,
+ 56.70438766479492,
+ 1.8434585332870483,
+ 99.46284484863281,
+ 57.46807861328125,
+ 38.466827392578125,
+ 38.081748962402344,
+ -25.695144653320312,
+ 92.8102798461914,
+ -87.58920288085938,
+ -84.74308776855469,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 1D tensor options.permutation",
+ "inputs": {
+ "input": {
+ "shape": [24],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "options": {
+ "permutation": [0]
+ },
+ "expected": {
+ "name": "output",
+ "shape": [24],
+ "data": [
+ -45.67443084716797,
+ 53.45924758911133,
+ -60.118492126464844,
+ 38.081748962402344,
+ 78.64247131347656,
+ -69.25324249267578,
+ 1.8434585332870483,
+ 92.8102798461914,
+ 56.100074768066406,
+ 77.05838012695312,
+ 57.46807861328125,
+ -84.74308776855469,
+ 46.38539123535156,
+ -84.89764404296875,
+ 56.70438766479492,
+ -25.695144653320312,
+ 5.62217378616333,
+ -25.66281509399414,
+ 99.46284484863281,
+ -87.58920288085938,
+ -65.3779067993164,
+ -66.00990295410156,
+ 38.466827392578125,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 2D tensor options.permutation",
+ "inputs": {
+ "input": {
+ "shape": [4, 6],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "options": {
+ "permutation": [1, 0]
+ },
+ "expected": {
+ "name": "output",
+ "shape": [6, 4],
+ "data": [
+ -45.67443084716797,
+ 1.8434585332870483,
+ 46.38539123535156,
+ 99.46284484863281,
+ 53.45924758911133,
+ 92.8102798461914,
+ -84.89764404296875,
+ -87.58920288085938,
+ -60.118492126464844,
+ 56.100074768066406,
+ 56.70438766479492,
+ -65.3779067993164,
+ 38.081748962402344,
+ 77.05838012695312,
+ -25.695144653320312,
+ -66.00990295410156,
+ 78.64247131347656,
+ 57.46807861328125,
+ 5.62217378616333,
+ 38.466827392578125,
+ -69.25324249267578,
+ -84.74308776855469,
+ -25.66281509399414,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 3D tensor options.permutation",
+ "inputs": {
+ "input": {
+ "shape": [2, 3, 4],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "options": {
+ "permutation": [2, 0, 1]
+ },
+ "expected": {
+ "name": "output",
+ "shape": [4, 2, 3],
+ "data": [
+ -45.67443084716797,
+ 78.64247131347656,
+ 56.100074768066406,
+ 46.38539123535156,
+ 5.62217378616333,
+ -65.3779067993164,
+ 53.45924758911133,
+ -69.25324249267578,
+ 77.05838012695312,
+ -84.89764404296875,
+ -25.66281509399414,
+ -66.00990295410156,
+ -60.118492126464844,
+ 1.8434585332870483,
+ 57.46807861328125,
+ 56.70438766479492,
+ 99.46284484863281,
+ 38.466827392578125,
+ 38.081748962402344,
+ 92.8102798461914,
+ -84.74308776855469,
+ -25.695144653320312,
+ -87.58920288085938,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 4D tensor options.permutation",
+ "inputs": {
+ "input": {
+ "shape": [1, 2, 3, 4],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "options": {
+ "permutation": [2, 3, 0, 1]
+ },
+ "expected": {
+ "name": "output",
+ "shape": [3, 4, 1, 2],
+ "data": [
+ -45.67443084716797,
+ 46.38539123535156,
+ 53.45924758911133,
+ -84.89764404296875,
+ -60.118492126464844,
+ 56.70438766479492,
+ 38.081748962402344,
+ -25.695144653320312,
+ 78.64247131347656,
+ 5.62217378616333,
+ -69.25324249267578,
+ -25.66281509399414,
+ 1.8434585332870483,
+ 99.46284484863281,
+ 92.8102798461914,
+ -87.58920288085938,
+ 56.100074768066406,
+ -65.3779067993164,
+ 77.05838012695312,
+ -66.00990295410156,
+ 57.46807861328125,
+ 38.466827392578125,
+ -84.74308776855469,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ },
+ {
+ "name": "transpose float32 5D tensor options.permutation",
+ "inputs": {
+ "input": {
+ "shape": [1, 2, 1, 3, 4],
+ "data": [
+ -45.67443169971317,
+ 53.45924798828125,
+ -60.118491676622114,
+ 38.08174802652866,
+ 78.64247328659363,
+ -69.2532431989057,
+ 1.843458570865181,
+ 92.81028097440239,
+ 56.10007526080264,
+ 77.05838267016932,
+ 57.46807874077655,
+ -84.74308916696364,
+ 46.38539267170415,
+ -84.89764374240352,
+ 56.70438712681607,
+ -25.69514467758806,
+ 5.622173913750174,
+ -25.6628149156966,
+ 99.46284660658401,
+ -87.58919988335086,
+ -65.37790624507953,
+ -66.00990219021253,
+ 38.46682821671709,
+ 2.1999381880991393
+ ],
+ "type": "float32"
+ }
+ },
+ "options": {
+ "permutation": [1, 3, 0, 4, 2]
+ },
+ "expected": {
+ "name": "output",
+ "shape": [2, 3, 1, 4, 1],
+ "data": [
+ -45.67443084716797,
+ 53.45924758911133,
+ -60.118492126464844,
+ 38.081748962402344,
+ 78.64247131347656,
+ -69.25324249267578,
+ 1.8434585332870483,
+ 92.8102798461914,
+ 56.100074768066406,
+ 77.05838012695312,
+ 57.46807861328125,
+ -84.74308776855469,
+ 46.38539123535156,
+ -84.89764404296875,
+ 56.70438766479492,
+ -25.695144653320312,
+ 5.62217378616333,
+ -25.66281509399414,
+ 99.46284484863281,
+ -87.58920288085938,
+ -65.3779067993164,
+ -66.00990295410156,
+ 38.466827392578125,
+ 2.1999382972717285
+ ],
+ "type": "float32"
+ }
+ }
+ ]
+} \ No newline at end of file