19#include "kernels/Utils.h"
39 switch (
input()->element_type())
41 case DataType::FLOAT32:
45 throw std::runtime_error(
"luci-intp Abs Unsupported type.");
49template <
typename T>
void Abs::eval()
const
51 const auto *input_data =
input()->
data<T>();
56 for (
int i = 0; i <
size; ++i)
58 output_data[i] = std::abs(input_data[i]);
void resize(const Shape &new_shape)
Abs(const Tensor *input, Tensor *output)
void execute() const override
void configure() override
const Tensor * input() const
#define LUCI_INTERPRETER_CHECK(cond)
tflite::RuntimeShape getTensorShape(const Tensor *tensor)