24 #ifndef ARM_COMPUTE_TEST_THRESHOLD_DATASET 25 #define ARM_COMPUTE_TEST_THRESHOLD_DATASET 40 using type = std::tuple<uint8_t, uint8_t, uint8_t, ThresholdType, uint8_t>;
44 iterator(std::vector<uint8_t>::const_iterator threshold_it,
45 std::vector<uint8_t>::const_iterator false_value_it,
46 std::vector<uint8_t>::const_iterator true_value_it,
47 std::vector<ThresholdType>::const_iterator type_it,
48 std::vector<uint8_t>::const_iterator upper_it)
49 : _threshold_it{ std::move(threshold_it) },
50 _false_value_it{ std::move(false_value_it) },
51 _true_value_it{ std::move(true_value_it) },
52 _type_it{ std::move(type_it) },
53 _upper_it{ std::move(upper_it) }
60 description <<
"Threshold=" <<
static_cast<unsigned>(*_threshold_it) <<
":";
61 description <<
"FalseValue_=" << std::boolalpha << static_cast<unsigned>(*_false_value_it) <<
":";
62 description <<
"TrueValue=" << std::boolalpha << static_cast<unsigned>(*_true_value_it) <<
":";
64 description <<
"Upper=" <<
static_cast<unsigned>(*_upper_it);
66 return description.str();
71 return std::make_tuple(*_threshold_it, *_false_value_it, *_true_value_it, *_type_it, *_upper_it);
86 std::vector<uint8_t>::const_iterator _threshold_it;
87 std::vector<uint8_t>::const_iterator _false_value_it;
88 std::vector<uint8_t>::const_iterator _true_value_it;
89 std::vector<ThresholdType>::const_iterator _type_it;
90 std::vector<uint8_t>::const_iterator _upper_it;
95 return iterator(_thresholds.begin(), _false_values.begin(), _true_values.begin(), _types.begin(), _uppers.begin());
105 _thresholds.emplace_back(std::move(threshold));
106 _false_values.emplace_back(std::move(false_value));
107 _true_values.emplace_back(std::move(true_value));
108 _types.emplace_back(std::move(threshold_type));
109 _uppers.emplace_back(std::move(upper));
117 std::vector<uint8_t> _thresholds{};
118 std::vector<uint8_t> _false_values{};
119 std::vector<uint8_t> _true_values{};
120 std::vector<ThresholdType> _types{};
121 std::vector<uint8_t> _uppers{};
void add_config(uint8_t threshold, uint8_t false_value, uint8_t true_value, ThresholdType threshold_type, uint8_t upper)
fixed_point< T > min(fixed_point< T > x, fixed_point< T > y)
std::string description() const
std::tuple< uint8_t, uint8_t, uint8_t, ThresholdType, uint8_t > type
ThresholdType
Threshold mode.
This file contains all available output stages for GEMMLowp on OpenCL.
iterator(std::vector< uint8_t >::const_iterator threshold_it, std::vector< uint8_t >::const_iterator false_value_it, std::vector< uint8_t >::const_iterator true_value_it, std::vector< ThresholdType >::const_iterator type_it, std::vector< uint8_t >::const_iterator upper_it)
ThresholdDataset::type operator*() const
Threshold with two values.
Threshold with one value.
SimpleTensor< T > threshold(const SimpleTensor< T > &src, T threshold, T false_value, T true_value, ThresholdType type, T upper)