blob: 6dd17862caf345f4c6ab4dde1e65f634b5e62a19 [file] [log] [blame]
// Generated from space_to_batch_float_2.mod.py
// DO NOT EDIT
// clang-format off
#include "TestHarness.h"
using namespace test_helper;
namespace generated_tests::space_to_batch_float_2 {
const TestModel& get_test_model() {
static TestModel model = {
.expectedMultinomialDistributionTolerance = 0,
.inputIndexes = {0},
.isRelaxed = false,
.operands = {{
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 10.0f}),
.dimensions = {1, 5, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({3, 2}),
.dimensions = {2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({1, 0, 2, 0}),
.dimensions = {2, 2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f, 0.0f, 0.0f, 5.0f, 0.0f, 0.0f, 0.0f, 6.0f, 0.0f, 1.0f, 0.0f, 7.0f, 0.0f, 2.0f, 0.0f, 8.0f, 0.0f, 3.0f, 0.0f, 9.0f, 0.0f, 4.0f, 0.0f, 10.0f}),
.dimensions = {6, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_OUTPUT,
.numberOfConsumers = 0,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}},
.operations = {{
.inputs = {0, 1, 2},
.outputs = {3},
.type = TestOperationType::SPACE_TO_BATCH_ND
}},
.outputIndexes = {3}
};
return model;
}
} // namespace generated_tests::space_to_batch_float_2
namespace generated_tests::space_to_batch_float_2 {
const TestModel& get_test_model_all_inputs_as_internal() {
static TestModel model = {
.expectedMultinomialDistributionTolerance = 0,
.inputIndexes = {4},
.isRelaxed = false,
.operands = {{
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({}),
.dimensions = {1, 5, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::TEMPORARY_VARIABLE,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({3, 2}),
.dimensions = {2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({1, 0, 2, 0}),
.dimensions = {2, 2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::CONSTANT_COPY,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f, 0.0f, 0.0f, 5.0f, 0.0f, 0.0f, 0.0f, 6.0f, 0.0f, 1.0f, 0.0f, 7.0f, 0.0f, 2.0f, 0.0f, 8.0f, 0.0f, 3.0f, 0.0f, 9.0f, 0.0f, 4.0f, 0.0f, 10.0f}),
.dimensions = {6, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_OUTPUT,
.numberOfConsumers = 0,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 10.0f}),
.dimensions = {1, 5, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.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
}, {
.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 = {4, 5, 6},
.outputs = {0},
.type = TestOperationType::ADD
}, {
.inputs = {0, 1, 2},
.outputs = {3},
.type = TestOperationType::SPACE_TO_BATCH_ND
}},
.outputIndexes = {3}
};
return model;
}
} // namespace generated_tests::space_to_batch_float_2
namespace generated_tests::space_to_batch_float_2 {
const TestModel& get_test_model_all_tensors_as_inputs() {
static TestModel model = {
.expectedMultinomialDistributionTolerance = 0,
.inputIndexes = {0, 1, 2},
.isRelaxed = false,
.operands = {{
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 10.0f}),
.dimensions = {1, 5, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({3, 2}),
.dimensions = {2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({1, 0, 2, 0}),
.dimensions = {2, 2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f, 0.0f, 0.0f, 5.0f, 0.0f, 0.0f, 0.0f, 6.0f, 0.0f, 1.0f, 0.0f, 7.0f, 0.0f, 2.0f, 0.0f, 8.0f, 0.0f, 3.0f, 0.0f, 9.0f, 0.0f, 4.0f, 0.0f, 10.0f}),
.dimensions = {6, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_OUTPUT,
.numberOfConsumers = 0,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}},
.operations = {{
.inputs = {0, 1, 2},
.outputs = {3},
.type = TestOperationType::SPACE_TO_BATCH_ND
}},
.outputIndexes = {3}
};
return model;
}
} // namespace generated_tests::space_to_batch_float_2
namespace generated_tests::space_to_batch_float_2 {
const TestModel& get_test_model_all_tensors_as_inputs_all_inputs_as_internal() {
static TestModel model = {
.expectedMultinomialDistributionTolerance = 0,
.inputIndexes = {1, 2, 4},
.isRelaxed = false,
.operands = {{
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({}),
.dimensions = {1, 5, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::TEMPORARY_VARIABLE,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({3, 2}),
.dimensions = {2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<int32_t>({1, 0, 2, 0}),
.dimensions = {2, 2},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_INT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({0.0f, 0.0f, 0.0f, 5.0f, 0.0f, 0.0f, 0.0f, 6.0f, 0.0f, 1.0f, 0.0f, 7.0f, 0.0f, 2.0f, 0.0f, 8.0f, 0.0f, 3.0f, 0.0f, 9.0f, 0.0f, 4.0f, 0.0f, 10.0f}),
.dimensions = {6, 2, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_OUTPUT,
.numberOfConsumers = 0,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.channelQuant = {},
.data = TestBuffer::createFromVector<float>({1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f, 7.0f, 8.0f, 9.0f, 10.0f}),
.dimensions = {1, 5, 2, 1},
.isIgnored = false,
.lifetime = TestOperandLifeTime::MODEL_INPUT,
.numberOfConsumers = 1,
.scale = 0.0f,
.type = TestOperandType::TENSOR_FLOAT32,
.zeroPoint = 0
}, {
.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
}, {
.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 = {4, 5, 6},
.outputs = {0},
.type = TestOperationType::ADD
}, {
.inputs = {0, 1, 2},
.outputs = {3},
.type = TestOperationType::SPACE_TO_BATCH_ND
}},
.outputIndexes = {3}
};
return model;
}
} // namespace generated_tests::space_to_batch_float_2