15 explicit SubtractionFixture(
const std::string & inputShape1,
16 const std::string & inputShape2,
17 const std::string & outputShape,
18 const std::string & dataType)
26 layer_type: "InputLayer", 32 layerName: "inputLayer1", 36 connection: {sourceLayerIndex:0, outputSlotIndex:0 }, 41 dimensions: )" + inputShape1 + R"(, 42 dataType: )" + dataType + R"( 49 layer_type: "InputLayer", 55 layerName: "inputLayer2", 59 connection: {sourceLayerIndex:0, outputSlotIndex:0 }, 64 dimensions: )" + inputShape2 + R"(, 65 dataType: )" + dataType + R"( 72 layer_type: "SubtractionLayer", 76 layerName: "subtractionLayer", 77 layerType: "Subtraction", 80 connection: {sourceLayerIndex:0, outputSlotIndex:0 }, 84 connection: {sourceLayerIndex:1, outputSlotIndex:0 }, 89 dimensions: )" + outputShape + R"(, 90 dataType: )" + dataType + R"( 96 layer_type: "OutputLayer", 102 layerName: "outputLayer", 106 connection: {sourceLayerIndex:2, outputSlotIndex:0 }, 111 dimensions: )" + outputShape + R"(, 112 dataType: )" + dataType + R"( 123 struct SimpleSubtractionFixture : SubtractionFixture
125 SimpleSubtractionFixture() : SubtractionFixture(
"[ 1, 4 ]",
128 "QuantisedAsymm8") {}
131 struct SimpleSubtractionFixture2 : SubtractionFixture
133 SimpleSubtractionFixture2() : SubtractionFixture(
"[ 1, 4 ]",
139 struct SimpleSubtractionFixtureBroadcast : SubtractionFixture
141 SimpleSubtractionFixtureBroadcast() : SubtractionFixture(
"[ 1, 4 ]",
149 RunTest<2, armnn::DataType::QAsymmU8>(
151 {{
"inputLayer1", { 4, 5, 6, 7 }},
152 {
"inputLayer2", { 3, 2, 1, 0 }}},
153 {{
"outputLayer", { 1, 3, 5, 7 }}});
158 RunTest<2, armnn::DataType::Float32>(
160 {{
"inputLayer1", { 4, 5, 6, 7 }},
161 {
"inputLayer2", { 3, 2, 1, 0 }}},
162 {{
"outputLayer", { 1, 3, 5, 7 }}});
167 RunTest<2, armnn::DataType::Float32>(
169 {{
"inputLayer1", { 4, 5, 6, 7 }},
170 {
"inputLayer2", { 2 }}},
171 {{
"outputLayer", { 2, 3, 4, 5 }}});
TEST_CASE_FIXTURE(ClContextControlFixture, "CopyBetweenNeonAndGpu")
TEST_SUITE("Deserializer_Subtraction")