24.02.1
|
#include "arm_compute/core/Error.h"
#include "arm_compute/core/utils/misc/Traits.h"
#include "support/AclRequires.h"
#include "support/ToolchainSupport.h"
#include <cmath>
Go to the source code of this file.
Namespaces | |
arm_compute | |
Copyright (c) 2017-2024 Arm Limited. | |
arm_compute::utils | |
arm_compute::utils::rounding | |
Enumerations | |
enum | RoundingMode { TO_ZERO, AWAY_FROM_ZERO, HALF_TO_ZERO, HALF_AWAY_FROM_ZERO, HALF_UP, HALF_DOWN, HALF_EVEN } |
Rounding mode. More... | |
Functions | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_to_zero (T value) |
Round floating-point value with round to zero. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_away_from_zero (T value) |
Round floating-point value with round away from zero. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_half_to_zero (T value) |
Round floating-point value with half value rounding towards zero. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_half_away_from_zero (T value) |
Round floating-point value with half value rounding away from zero. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_half_up (T value) |
Round floating-point value with half value rounding to positive infinity. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_half_down (T value) |
Round floating-point value with half value rounding to negative infinity. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round_half_even (T value, T epsilon=std::numeric_limits< T >::epsilon()) |
Round floating-point value with half value rounding to nearest even. More... | |
template<typename T , ARM_COMPUTE_REQUIRES_TA(traits::is_floating_point< T >::value) > | |
T | round (T value, RoundingMode rounding_mode) |
Round floating-point value given a rounding mode. More... | |