Compute Library
 21.02
Helpers.h File Reference
#include "arm_compute/core/Types.h"
#include "arm_compute/core/Utils.h"
#include "support/Half.h"
#include "tests/Globals.h"
#include "tests/SimpleTensor.h"
#include <math.h>
#include <random>
#include <type_traits>
#include <utility>

Go to the source code of this file.

Data Structures

struct  is_floating_point< T >
 
struct  is_floating_point< half >
 
struct  HarrisCornersParameters
 Parameters of Harris Corners algorithm. More...
 
struct  CannyEdgeParameters
 Parameters of Canny edge algorithm. More...
 

Namespaces

 arm_compute
 Copyright (c) 2017-2021 Arm Limited.
 
 arm_compute::test
 
 arm_compute::test::validation
 

Functions

template<typename T >
std::pair< T, T > get_activation_layer_test_bounds (ActivationLayerInfo::ActivationFunction activation, DataType data_type)
 Helper function to get the testing range for each activation layer. More...
 
void fill_mask_from_pattern (uint8_t *mask, int cols, int rows, MatrixPattern pattern)
 Fill mask with the corresponding given pattern. More...
 
TensorShape calculate_depth_concatenate_shape (const std::vector< TensorShape > &input_shapes)
 Calculate output tensor shape give a vector of input tensor to concatenate. More...
 
TensorShape calculate_concatenate_shape (const std::vector< TensorShape > &input_shapes, size_t axis)
 Calculate output tensor shape for the concatenate operation along a given axis. More...
 
HarrisCornersParameters harris_corners_parameters ()
 Generate parameters for Harris Corners algorithm. More...
 
CannyEdgeParameters canny_edge_parameters ()
 Generate parameters for Canny edge algorithm. More...
 
template<typename T >
void fill_lookuptable (T &&table)
 Helper function to fill the Lut random by a ILutAccessor. More...
 
template<typename T >
SimpleTensor< float > convert_from_asymmetric (const SimpleTensor< T > &src)
 Convert an asymmetric quantized simple tensor into float using tensor quantization information. More...
 
template<typename T >
SimpleTensor< T > convert_to_asymmetric (const SimpleTensor< float > &src, const QuantizationInfo &quantization_info)
 Convert float simple tensor into quantized using specified quantization information. More...
 
template<typename T >
SimpleTensor< float > convert_from_symmetric (const SimpleTensor< T > &src)
 Convert quantized simple tensor into float using tensor quantization information. More...
 
template<typename T >
SimpleTensor< T > convert_to_symmetric (const SimpleTensor< float > &src, const QuantizationInfo &quantization_info)
 Convert float simple tensor into quantized using specified quantization information. More...
 
template<typename T >
void matrix_multiply (const SimpleTensor< T > &a, const SimpleTensor< T > &b, SimpleTensor< T > &out)
 Matrix multiply between 2 float simple tensors. More...
 
template<typename T >
void transpose_matrix (const SimpleTensor< T > &in, SimpleTensor< T > &out)
 Transpose matrix. More...
 
template<typename T >
void get_tile (const SimpleTensor< T > &in, SimpleTensor< T > &tile, const Coordinates &coord)
 Get a 2D tile from a tensor. More...
 
template<typename T >
void zeros (SimpleTensor< T > &in, const Coordinates &anchor, const TensorShape &shape)
 Fill with zeros the input tensor in the area defined by anchor and shape. More...
 
std::pair< int, int > get_quantized_bounds (const QuantizationInfo &quant_info, float min, float max)
 Helper function to compute quantized min and max bounds. More...
 
std::pair< int, int > get_quantized_qasymm8_signed_bounds (const QuantizationInfo &quant_info, float min, float max)
 Helper function to compute asymmetric quantized signed min and max bounds. More...
 
std::pair< int, int > get_symm_quantized_per_channel_bounds (const QuantizationInfo &quant_info, float min, float max, size_t channel_id=0)
 Helper function to compute symmetric quantized min and max bounds. More...