diff options
author | Isabella Gottardi <isabella.gottardi@arm.com> | 2019-02-14 18:07:36 +0000 |
---|---|---|
committer | Georgios Pinitas <georgios.pinitas@arm.com> | 2019-02-15 16:49:05 +0000 |
commit | e82cb042e6d53bc6870338e209e015abb426b550 (patch) | |
tree | 11e4f5ac9071a851003a4327b3a0bb89c6f5539c /src/core/CL/kernels/CLReductionOperationKernel.cpp | |
parent | 80c88167ce5d891b05e0e9f012e99be5a7e7ee9e (diff) | |
download | ComputeLibrary-e82cb042e6d53bc6870338e209e015abb426b550.tar.gz |
COMPMID-1710: Add check on different input/output quantization info were not supported
Change-Id: Id64dab5e2de341316238506d4fb3ab82b992753d
Signed-off-by: Isabella Gottardi <isabella.gottardi@arm.com>
Reviewed-on: https://review.mlplatform.org/697
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com>
Diffstat (limited to 'src/core/CL/kernels/CLReductionOperationKernel.cpp')
-rw-r--r-- | src/core/CL/kernels/CLReductionOperationKernel.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/core/CL/kernels/CLReductionOperationKernel.cpp b/src/core/CL/kernels/CLReductionOperationKernel.cpp index 45aa810517..451f52071c 100644 --- a/src/core/CL/kernels/CLReductionOperationKernel.cpp +++ b/src/core/CL/kernels/CLReductionOperationKernel.cpp @@ -62,6 +62,7 @@ Status validate_arguments(const ITensorInfo *input, const ITensorInfo *output, u else { ARM_COMPUTE_RETURN_ERROR_ON_MISMATCHING_DATA_TYPES(input, output); + ARM_COMPUTE_RETURN_ERROR_ON_MISMATCHING_QUANTIZATION_INFO(input, output); } } @@ -75,7 +76,7 @@ std::tuple<Status, Window> validate_and_configure_window(ITensorInfo *input, ITe output_shape.set(axis, 1); const bool is_arg_min_max = (op == ReductionOperation::ARG_IDX_MIN || op == ReductionOperation::ARG_IDX_MAX); DataType output_data_type = is_arg_min_max ? DataType::U32 : input->data_type(); - auto_init_if_empty(*output, output_shape, 1, output_data_type); + auto_init_if_empty(*output, output_shape, 1, output_data_type, input->quantization_info()); const unsigned int num_elems_processed_per_iteration = (is_data_type_quantized(input->data_type()) && (axis == 0)) ? 1 : 16; Window win = calculate_max_window(*input, Steps(num_elems_processed_per_iteration)); |