Source code

Revision control

Copy as Markdown

Other Tools

{
"tests": [
{
"name": "greater float32 0D scalar",
"inputs": {
"a": {
"shape": [],
"data": [
3.6851014232119716
],
"type": "float32"
},
"b": {
"shape": [],
"data": [
1.7231997782518338
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [],
"data": [
1
],
"type": "uint8"
}
},
{
"name": "greater float32 1D constant tensors",
"inputs": {
"a": {
"shape": [24],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32",
"constant": true
},
"b": {
"shape": [24],
"data": [
-6.155234276085855,
-4.023341341511664,
5.9525983178014386,
2.3066237309537883,
-2.7692292888690817,
-0.9711201246625745,
1.2222066588909755,
4.590261643319389,
9.101232896619365,
-4.997007709812857,
-4.807293508200368,
8.919360491720344,
0.900502762346548,
-2.8414556193065543,
-2.8280412040974845,
8.479845345966147,
-7.840679465875833,
9.213960197279938,
4.982364937519449,
-2.5073192467116145,
-4.518013838492472,
8.351094603114355,
-6.161073167579363,
0.7364829132932815
],
"type": "float32",
"constant": true
}
},
"expected": {
"name": "output",
"shape": [24],
"data": [
1,
0,
0,
1,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 1D tensors",
"inputs": {
"a": {
"shape": [24],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [24],
"data": [
-6.155234276085855,
-4.023341341511664,
5.9525983178014386,
2.3066237309537883,
-2.7692292888690817,
-0.9711201246625745,
1.2222066588909755,
4.590261643319389,
9.101232896619365,
-4.997007709812857,
-4.807293508200368,
8.919360491720344,
0.900502762346548,
-2.8414556193065543,
-2.8280412040974845,
8.479845345966147,
-7.840679465875833,
9.213960197279938,
4.982364937519449,
-2.5073192467116145,
-4.518013838492472,
8.351094603114355,
-6.161073167579363,
0.7364829132932815
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [24],
"data": [
1,
0,
0,
1,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 2D tensors",
"inputs": {
"a": {
"shape": [4, 6],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [4, 6],
"data": [
-6.155234276085855,
-4.023341341511664,
5.9525983178014386,
2.3066237309537883,
-2.7692292888690817,
-0.9711201246625745,
1.2222066588909755,
4.590261643319389,
9.101232896619365,
-4.997007709812857,
-4.807293508200368,
8.919360491720344,
0.900502762346548,
-2.8414556193065543,
-2.8280412040974845,
8.479845345966147,
-7.840679465875833,
9.213960197279938,
4.982364937519449,
-2.5073192467116145,
-4.518013838492472,
8.351094603114355,
-6.161073167579363,
0.7364829132932815
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [4, 6],
"data": [
1,
0,
0,
1,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 3D tensors",
"inputs": {
"a": {
"shape": [2, 3, 4],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [2, 3, 4],
"data": [
-6.155234276085855,
-4.023341341511664,
5.9525983178014386,
2.3066237309537883,
-2.7692292888690817,
-0.9711201246625745,
1.2222066588909755,
4.590261643319389,
9.101232896619365,
-4.997007709812857,
-4.807293508200368,
8.919360491720344,
0.900502762346548,
-2.8414556193065543,
-2.8280412040974845,
8.479845345966147,
-7.840679465875833,
9.213960197279938,
4.982364937519449,
-2.5073192467116145,
-4.518013838492472,
8.351094603114355,
-6.161073167579363,
0.7364829132932815
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 3, 4],
"data": [
1,
0,
0,
1,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 4D tensors",
"inputs": {
"a": {
"shape": [2, 2, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [2, 2, 2, 3],
"data": [
-6.155234276085855,
-4.023341341511664,
5.9525983178014386,
2.3066237309537883,
-2.7692292888690817,
-0.9711201246625745,
1.2222066588909755,
4.590261643319389,
9.101232896619365,
-4.997007709812857,
-4.807293508200368,
8.919360491720344,
0.900502762346548,
-2.8414556193065543,
-2.8280412040974845,
8.479845345966147,
-7.840679465875833,
9.213960197279938,
4.982364937519449,
-2.5073192467116145,
-4.518013838492472,
8.351094603114355,
-6.161073167579363,
0.7364829132932815
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 2, 3],
"data": [
1,
0,
0,
1,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 5D tensors",
"inputs": {
"a": {
"shape": [2, 2, 1, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [2, 2, 1, 2, 3],
"data": [
-6.155234276085855,
-4.023341341511664,
5.9525983178014386,
2.3066237309537883,
-2.7692292888690817,
-0.9711201246625745,
1.2222066588909755,
4.590261643319389,
9.101232896619365,
-4.997007709812857,
-4.807293508200368,
8.919360491720344,
0.900502762346548,
-2.8414556193065543,
-2.8280412040974845,
8.479845345966147,
-7.840679465875833,
9.213960197279938,
4.982364937519449,
-2.5073192467116145,
-4.518013838492472,
8.351094603114355,
-6.161073167579363,
0.7364829132932815
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 1, 2, 3],
"data": [
1,
0,
0,
1,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0,
1,
0,
1,
0,
0,
1,
1,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 broadcast 0D to 4D",
"inputs": {
"a": {
"shape": [],
"data": [
6.22164122692616
],
"type": "float32"
},
"b": {
"shape": [2, 2, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 2, 3],
"data": [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
0,
1,
1,
1,
1,
1,
1,
1
],
"type": "uint8"
}
},
{
"name": "greater float32 broadcast 1D to 4D",
"inputs": {
"a": {
"shape": [1],
"data": [
6.22164122692616
],
"type": "float32"
},
"b": {
"shape": [2, 2, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 2, 3],
"data": [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
0,
1,
1,
1,
1,
1,
1,
1
],
"type": "uint8"
}
},
{
"name": "greater float32 broadcast 2D to 4D",
"inputs": {
"a": {
"shape": [2, 2, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [2, 3],
"data": [
-2.684664470849163,
6.170023353490912,
9.487744366422781,
-2.555641152388084,
-2.0436435571200873,
8.533930402669746
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 2, 3],
"data": [
0,
0,
0,
1,
1,
0,
1,
0,
0,
0,
1,
0,
1,
0,
0,
0,
1,
0,
1,
0,
0,
0,
1,
0
],
"type": "uint8"
}
},
{
"name": "greater float32 broadcast 3D to 4D",
"inputs": {
"a": {
"shape": [2, 2, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
},
"b": {
"shape": [2, 2, 1],
"data": [
-7.099076082908593,
-7.781408238233589,
8.782817806924719,
-8.948624418290514
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 2, 3],
"data": [
1,
0,
1,
1,
1,
1,
0,
0,
0,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
1,
1,
1
],
"type": "uint8"
}
},
{
"name": "greater float32 broadcast 4D to 4D",
"inputs": {
"a": {
"shape": [1, 1, 1, 1],
"data": [
6.22164122692616
],
"type": "float32"
},
"b": {
"shape": [2, 2, 2, 3],
"data": [
-5.394711458674926,
-7.189248660357093,
-3.108176577372168,
4.977657240654292,
5.111654167277017,
-1.538657969029952,
1.4143663572463936,
-0.9362112515011844,
-6.029961511382025,
-3.0134198095493225,
0.17085531331013115,
7.395327146335315,
7.178691694492247,
-4.826237489933036,
-2.0204401018636275,
-3.267887959306748,
8.944384478538513,
-5.9321008596864555,
0.7069857360876597,
2.7764204012258844,
0.9788337909419198,
-6.254901877789392,
4.40903450389083,
-6.775286805113776
],
"type": "float32"
}
},
"expected": {
"name": "output",
"shape": [2, 2, 2, 3],
"data": [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
1,
1,
1,
0,
1,
1,
1,
1,
1,
1,
1
],
"type": "uint8"
}
}
]
}