39 template <
typename T,
typename U>
42 std::vector<SimpleTensor<T>> tmp_pyramid(pyramid);
44 const size_t last_level = pyramid.size() - 1;
51 for(
size_t i = last_level; i-- > 0;)
53 const float scale_x =
static_cast<float>(tmp_pyramid[i].shape().x()) / tmp_pyramid[i + 1].
shape().x();
54 const float scale_y =
static_cast<float>(tmp_pyramid[i].shape().y()) / tmp_pyramid[i + 1].
shape().y();
BorderMode
Methods available to handle borders.
1 channel, 1 U8 per channel
DataType data_type() const override
Data type of the tensor.
Output values are defined to match the source pixel whose center is nearest to the sample position...
SimpleTensor< T > arithmetic_operation(ArithmeticOperation op, const SimpleTensor< T > &src1, const SimpleTensor< T > &src2, SimpleTensor< T > &dst, ConvertPolicy convert_policy)
Copyright (c) 2017-2021 Arm Limited.
Samples are taken at pixel center.
Simple tensor object that stores elements in a consecutive chunk of memory.
SimpleTensor< T > scale(const SimpleTensor< T > &src, float scale_x, float scale_y, InterpolationPolicy policy, BorderMode border_mode, T constant_border_value, SamplingPolicy sampling_policy, bool ceil_policy_scale, bool align_corners)
SimpleTensor< U > laplacian_reconstruct(const std::vector< SimpleTensor< T >> &pyramid, const SimpleTensor< T > &low_res, BorderMode border_mode, T constant_border_value)
DataType
Available data types.