blob: 626c92465bf77a25e17cdd176bd4f1bbe9f65845 [file] [log] [blame]
// Generated from conv_float_weights_as_inputs.mod.py
// DO NOT EDIT
// clang-format off
#include "TestHarness.h"
using namespace test_helper;
namespace generated_tests::conv_float_weights_as_inputs {
const TestModel& get_test_model() {
static TestModel model = {
.expectFailure = false,
.expectedMultinomialDistributionTolerance = 0,
.isRelaxed = false,
.main = {
.inputIndexes = {0, 1, 2},
.operands = {{ // op1
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({1.0f, 1.0f, 1.0f, 1.0f, 0.5f, 1.0f, 1.0f, 1.0f, 1.0f}),
.dimensions = {1, 3, 3, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // op2
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.25f, 0.25f, 0.25f, 0.25f}),
.dimensions = {1, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // op3
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f}),
.dimensions = {1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // pad0
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 4,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // stride
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({1}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 2,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // act
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // op4
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.875f, 0.875f, 0.875f, 0.875f}),
.dimensions = {1, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_OUTPUT,
.numberOfConsumers = 0,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}},
.operations = {{
.inputs = {0, 1, 2, 3, 3, 3, 3, 4, 4, 5},
.outputs = {6},
.type = TestOperationType::CONV_2D
}},
.outputIndexes = {6}
},
.minSupportedVersion = TestHalVersion::V1_0,
.referenced = {}
};
return model;
}
const auto dummy_test_model = TestModelManager::get().add("conv_float_weights_as_inputs", get_test_model());
} // namespace generated_tests::conv_float_weights_as_inputs
namespace generated_tests::conv_float_weights_as_inputs {
const TestModel& get_test_model_all_inputs_as_internal() {
static TestModel model = {
.expectFailure = false,
.expectedMultinomialDistributionTolerance = 0,
.isRelaxed = false,
.main = {
.inputIndexes = {7, 10, 13},
.operands = {{ // op1
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({}),
.dimensions = {1, 3, 3, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::TEMPORARY_VARIABLE,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // op2
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({}),
.dimensions = {1, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::TEMPORARY_VARIABLE,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // op3
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({}),
.dimensions = {1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::TEMPORARY_VARIABLE,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // pad0
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 4,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // stride
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({1}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 2,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // act
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // op4
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.875f, 0.875f, 0.875f, 0.875f}),
.dimensions = {1, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_OUTPUT,
.numberOfConsumers = 0,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // op1_new
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({1.0f, 1.0f, 1.0f, 1.0f, 0.5f, 1.0f, 1.0f, 1.0f, 1.0f}),
.dimensions = {1, 3, 3, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // placeholder
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f}),
.dimensions = {1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // param
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // op2_new
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.25f, 0.25f, 0.25f, 0.25f}),
.dimensions = {1, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // placeholder1
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f}),
.dimensions = {1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // param1
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}, { // op3_new
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f}),
.dimensions = {1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::SUBGRAPH_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // placeholder2
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f}),
.dimensions = {1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, { // param2
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({0}),
.dimensions = {},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::INT32,
.zeroPoint = 0
}},
.operations = {{
.inputs = {7, 8, 9},
.outputs = {0},
.type = TestOperationType::ADD
}, {
.inputs = {10, 11, 12},
.outputs = {1},
.type = TestOperationType::ADD
}, {
.inputs = {13, 14, 15},
.outputs = {2},
.type = TestOperationType::ADD
}, {
.inputs = {0, 1, 2, 3, 3, 3, 3, 4, 4, 5},
.outputs = {6},
.type = TestOperationType::CONV_2D
}},
.outputIndexes = {6}
},
.minSupportedVersion = TestHalVersion::V1_0,
.referenced = {}
};
return model;
}
const auto dummy_test_model_all_inputs_as_internal = TestModelManager::get().add("conv_float_weights_as_inputs_all_inputs_as_internal", get_test_model_all_inputs_as_internal());
} // namespace generated_tests::conv_float_weights_as_inputs