From a62973d62d5802c2e1e5d0a911be619ace9056a5 Mon Sep 17 00:00:00 2001 From: Franco Nieddu Date: Tue, 9 Jan 2024 17:17:51 +0100 Subject: [PATCH] test: add split tests again as we now support multile outputs --- mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.json | 2 +- mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.res | 5 +++-- mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.json | 2 +- mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.res | 6 ++++-- mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.json | 2 +- mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.res | 6 ++++-- 6 files changed, 14 insertions(+), 9 deletions(-) diff --git a/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.json b/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.json index d7cb6f4..b0c4055 100644 --- a/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.json +++ b/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.json @@ -1 +1 @@ -[{"memref": {"data": [0.90093994140625, 0.6243743896484375, 0.9480743408203125, 0.947784423828125, 0.0037078857421875, 0.2400970458984375, 0.4120635986328125, 0.0965576171875, 0.0577850341796875, 0.14410400390625, 0.18951416015625, 0.37921142578125, 0.1258544921875, 0.8603363037109375, 0.4984588623046875, 0.750885009765625, 0.62939453125, 0.7102813720703125, 0.47540283203125, 0.2939453125], "dims": [1, 20], "type": "f32"}}] \ No newline at end of file +[{"memref": {"data": [0.2933349609375, 0.1227569580078125, 0.6149139404296875, 0.943389892578125, 0.475830078125, 0.14007568359375, 0.291107177734375, 0.943084716796875, 0.0203094482421875, 0.21826171875, 0.2769317626953125, 0.4925537109375, 0.2345428466796875, 0.7003173828125, 0.077178955078125, 0.0085906982421875, 0.035675048828125, 0.886566162109375, 0.5161590576171875, 0.3329315185546875], "dims": [1, 20], "type": "f32"}}] \ No newline at end of file diff --git a/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.res b/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.res index 82cea07..3a07ea1 100644 --- a/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.res +++ b/mlir-assigner/tests/Ops/Onnx/Split/SplitSimple.res @@ -1,3 +1,4 @@ Result: -memref<1x10xf32>[0.18951416015625, 0.37921142578125, 0.1258544921875, 0.8603363037109375, 0.4984588623046875, 0.750885009765625, 0.62939453125, 0.7102813720703125, 0.47540283203125, 0.2939453125] -ADD THE ROWS HERE \ No newline at end of file +memref<1x10xf32>[0.2933349609375, 0.1227569580078125, 0.6149139404296875, 0.943389892578125, 0.475830078125, 0.14007568359375, 0.291107177734375, 0.943084716796875, 0.0203094482421875, 0.21826171875] +memref<1x10xf32>[0.2769317626953125, 0.4925537109375, 0.2345428466796875, 0.7003173828125, 0.077178955078125, 0.0085906982421875, 0.035675048828125, 0.886566162109375, 0.5161590576171875, 0.3329315185546875] +22 diff --git a/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.json b/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.json index 7edcef6..ad271d8 100644 --- a/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.json +++ b/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.json @@ -1 +1 @@ -[{"memref": {"data": [0.522979736328125, 0.679443359375, 0.0391845703125, 0.8433074951171875, 0.9461212158203125, 0.1768951416015625, 0.2410888671875, 0.9713134765625, 0.8756866455078125, 0.92327880859375, 0.841400146484375, 0.790191650390625, 0.44952392578125, 0.4233245849609375, 0.4760284423828125, 0.908111572265625, 0.319091796875, 0.3483734130859375, 0.31439208984375, 0.5734710693359375], "dims": [1, 20], "type": "f32"}}] \ No newline at end of file +[{"memref": {"data": [0.2693939208984375, 0.6679229736328125, 0.41497802734375, 0.747894287109375, 0.0548248291015625, 0.94830322265625, 0.3267059326171875, 0.9477996826171875, 0.748321533203125, 0.2707366943359375, 0.2700042724609375, 0.67193603515625, 0.2753753662109375, 0.0406036376953125, 0.4768218994140625, 0.9441680908203125, 0.5763092041015625, 0.1037139892578125, 0.853668212890625, 0.721160888671875], "dims": [1, 20], "type": "f32"}}] \ No newline at end of file diff --git a/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.res b/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.res index 7ad12e8..ecd87f4 100644 --- a/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.res +++ b/mlir-assigner/tests/Ops/Onnx/Split/SplitUneven.res @@ -1,3 +1,5 @@ Result: -memref<1x6xf32>[0.4760284423828125, 0.908111572265625, 0.319091796875, 0.3483734130859375, 0.31439208984375, 0.5734710693359375] -ADD THE ROWS HERE \ No newline at end of file +memref<1x7xf32>[0.2693939208984375, 0.6679229736328125, 0.41497802734375, 0.747894287109375, 0.0548248291015625, 0.94830322265625, 0.3267059326171875] +memref<1x7xf32>[0.9477996826171875, 0.748321533203125, 0.2707366943359375, 0.2700042724609375, 0.67193603515625, 0.2753753662109375, 0.0406036376953125] +memref<1x6xf32>[0.4768218994140625, 0.9441680908203125, 0.5763092041015625, 0.1037139892578125, 0.853668212890625, 0.721160888671875] +22 diff --git a/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.json b/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.json index c6c79de..840cc40 100644 --- a/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.json +++ b/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.json @@ -1 +1 @@ -[{"memref": {"data": [0.34674072265625, 0.1746368408203125, 0.9866485595703125, 0.589508056640625, 0.35015869140625, 0.8547515869140625, 0.743896484375, 0.1547088623046875, 0.5247344970703125, 0.460174560546875, 0.4203643798828125, 0.494659423828125, 0.5968780517578125, 0.624603271484375, 0.6593170166015625, 0.21978759765625, 0.7389373779296875, 0.8072967529296875, 0.504547119140625, 0.923065185546875], "dims": [1, 20], "type": "f32"}}, {"memref": {"data": [1, 10, 9], "dims": [3], "type": "int"}}] \ No newline at end of file +[{"memref": {"data": [0.31500244140625, 0.9777069091796875, 0.470306396484375, 0.463531494140625, 0.7454681396484375, 0.5622100830078125, 0.316131591796875, 0.5930328369140625, 0.014862060546875, 0.46112060546875, 0.17974853515625, 0.865386962890625, 0.1540374755859375, 0.4318695068359375, 0.095672607421875, 0.5402069091796875, 0.509857177734375, 0.5605010986328125, 0.7646636962890625, 0.1786651611328125], "dims": [1, 20], "type": "f32"}}] diff --git a/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.res b/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.res index f5da6cb..2bfce34 100644 --- a/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.res +++ b/mlir-assigner/tests/Ops/Onnx/Split/SplitVarInput.res @@ -1,3 +1,5 @@ Result: -memref<1x9xf32>[0.494659423828125, 0.5968780517578125, 0.624603271484375, 0.6593170166015625, 0.21978759765625, 0.7389373779296875, 0.8072967529296875, 0.504547119140625, 0.923065185546875] -ADD THE ROWS HERE \ No newline at end of file +memref<1x1xf32>[0.31500244140625] +memref<1x10xf32>[0.9777069091796875, 0.470306396484375, 0.463531494140625, 0.7454681396484375, 0.5622100830078125, 0.316131591796875, 0.5930328369140625, 0.014862060546875, 0.46112060546875, 0.17974853515625] +memref<1x9xf32>[0.865386962890625, 0.1540374755859375, 0.4318695068359375, 0.095672607421875, 0.5402069091796875, 0.509857177734375, 0.5605010986328125, 0.7646636962890625, 0.1786651611328125] +22