31 #include "tests/datasets/ImageFileDatasets.h" 32 #include "tests/datasets/ShapeDatasets.h" 37 #include "tests/validation/fixtures/FastCornersFixture.h" 48 const unsigned int bresenham_radius = 3;
50 const AbsoluteTolerance<float> tolerance(0.5f);
57 framework::dataset::
make("
Format", Format::U8)),
58 framework::dataset::
make("SuppressNonMax", {
false,
true })),
62 std::mt19937 gen(
library->seed());
63 std::uniform_int_distribution<uint8_t> int_dist(0, 255);
64 std::uniform_real_distribution<float> real_dist(0, 255);
66 const uint8_t constant_border_value = int_dist(gen);
71 src.info()->set_format(format);
79 fast_corners.configure(&src, threshold, suppress_nonmax, &corners,
border_mode, constant_border_value);
92 using NEFastCornersFixture = FastCornersValidationFixture<Tensor, Accessor, KeyPointArray, NEFastCorners, T>;
void set_accessed_elements(int elements)
Set number of accessed elements.
ArrayAccessor implementation for Array objects.
size_t num_values() const override
Number of elements of the tensor.
1 channel, 1 U8 per channel
PaddingCalculator calculator(shape.x(), 8)
std::enable_if< is_container< T >::value, ContainerDataset< T > >::type make(std::string name, T &&values)
Helper function to create a ContainerDataset.
void set_border_size(int size)
Set border size.
PaddingSize required_padding() const
Compute the required padding.
This file contains all available output stages for GEMMLowp on OpenCL.
void set_access_offset(int offset)
Set offset of the access relative to the current position.
#define TEST_SUITE(SUITE_NAME)
Array< KeyPoint > KeyPointArray
Array of Key Points.
FIXTURE_DATA_TEST_CASE(RunSmall, CLAbsoluteDifferenceFixture< uint8_t >, framework::DatasetMode::PRECOMMIT, combine(datasets::SmallShapes(), AbsoluteDifferenceU8Dataset))
validate(dst.info() ->valid_region(), dst_valid_region)
DatasetMode
Possible dataset modes.
FastCornersValidationFixture< Tensor, Accessor, KeyPointArray, NEFastCorners, T > NEFastCornersFixture
std::unique_ptr< AssetsLibrary > library
Format
Image colour formats.
T * buffer() override
Access to the buffer.
DataType data_type_from_format(Format format)
Return the data type used by a given single-planar pixel format.
DATA_TEST_CASE(Configuration, framework::DatasetMode::ALL, combine(concat(datasets::SmallShapes(), datasets::LargeShapes()), AbsoluteDifferenceU8Dataset), shape, data_type0, data_type1, output_data_type)
__kernel void fast_corners(__global uchar *input_ptr, uint input_stride_x, uint input_step_x, uint input_stride_y, uint input_step_y, uint input_offset_first_element_in_bytes, __global uchar *output_ptr, uint output_stride_x, uint output_step_x, uint output_stride_y, uint output_step_y, uint output_offset_first_element_in_bytes, float threshold_value)
Fast corners implementation.
TEST_SUITE_END() DATA_TEST_CASE(Configuration
ARM_COMPUTE_EXPECT(src.info() ->is_resizable(), framework::LogLevel::ERRORS)
Borders are left undefined.
void validate_keypoints(T target_first, T target_last, U reference_first, U reference_last, V tolerance=AbsoluteTolerance< float >(), float allowed_missing_percentage=5.f, float allowed_mismatch_percentage=5.f)
Validate key points.
combine(combine(combine(concat(datasets::SmallShapes(), datasets::LargeShapes()), framework::dataset::make("DataType",{DataType::U8, DataType::S16})), datasets::BorderModes()), framework::dataset::make("filter_size",{5}))
JoinDataset< T, U > concat(T &&dataset1, U &&dataset2)
Helper function to create a JoinDataset.
SimpleTensor< T > threshold(const SimpleTensor< T > &src, T threshold, T false_value, T true_value, ThresholdType type, T upper)
convolution configure & src