| 146 | } |
| 147 | |
| 148 | void AveragePool3dFP32PaddingValidTest(const std::vector<armnn::BackendId>& backends = {}) |
| 149 | { |
| 150 | // Set input data and expected output data. |
| 151 | std::vector<int32_t> inputShape = { 1, 2, 3, 4, 1 }; |
| 152 | std::vector<int32_t> outputShape = { 1, 1, 2, 3, 1 }; |
| 153 | |
| 154 | std::vector<float> inputValues = { 1, 2, 3, 4, 5, 6, |
| 155 | 1, 2, 3, 4, 5, 6, |
| 156 | 1, 2, 3, 4, 5, 6, |
| 157 | 1, 2, 3, 4, 5, 6 }; |
| 158 | std::vector<float> expectedOutputValues = { 3.5, 3, 2.5 }; |
| 159 | |
| 160 | // poolType string required to create the correct pooling operator |
| 161 | // Padding type required to create the padding in custom options |
| 162 | std::string poolType = "kAverage"; |
| 163 | TfLitePadding padding = kTfLitePaddingValid; |
| 164 | |
| 165 | Pooling3dTest<float>(poolType, |
| 166 | ::tflite::TensorType_FLOAT32, |
| 167 | inputShape, |
| 168 | outputShape, |
| 169 | inputValues, |
| 170 | expectedOutputValues, |
| 171 | backends, |
| 172 | padding, |
| 173 | 1, |
| 174 | 1, |
| 175 | 1, |
| 176 | 2, |
| 177 | 2, |
| 178 | 2); |
| 179 | } |
| 180 | |
| 181 | void AveragePool3dFP32PaddingSameTest(const std::vector<armnn::BackendId>& backends = {}) |
| 182 | { |