const ::arm_compute::ITensor *padding_size,
::arm_compute::ITensor *output_data,
const ::arm_compute::TensorShape &output_shape,
- const ::arm_compute::Coordinates &axises)
+ const ::arm_compute::Coordinates &axises, T zero_value)
{
assert(validate_arg(input_data, output_data, padding_size, axises) &&
out_w < pad_width_left || out_w >= (input_width + pad_width_left) ||
out_d < pad_depth_front || out_d >= (input_depth + pad_depth_front))
{
- *reinterpret_cast<T *>(output_data->ptr_to_element(output_id)) = 0;
+ *reinterpret_cast<T *>(output_data->ptr_to_element(output_id)) = zero_value;
}
else
{
case ::arm_compute::DataType::U8:
case ::arm_compute::DataType::QASYMM8:
ApplyPadding<uint8_t>(_input, _input->info()->tensor_shape(), _padding_size, _output,
- _output->info()->tensor_shape(), _axises);
+ _output->info()->tensor_shape(), _axises,
+ _input->info()->quantization_info().offset);
break;
case ::arm_compute::DataType::F32:
ApplyPadding<float>(_input, _input->info()->tensor_shape(), _padding_size, _output,
- _output->info()->tensor_shape(), _axises);
+ _output->info()->tensor_shape(), _axises, 0.0f);
break;
default:
ARM_COMPUTE_ERROR("DataType not supported");