18#include "kernels/Utils.h"
33 if (
input()->element_type() !=
output()->element_type())
35 throw std::runtime_error(
"Input/output tensor data type mismatch.");
42 switch (
input()->element_type())
44 case DataType::FLOAT32:
49 throw std::runtime_error(
"luci-intp Square Unsupported type.");
53void Square::evalFloat()
const
55 auto in = getTensorData<float>(
input());
56 auto out = getTensorData<float>(
output());
58 for (
auto i = in; i != in +
size; ++i)
void resize(const Shape &new_shape)
void configure() override
Square(const Tensor *input, Tensor *output)
void execute() const override
const Tensor * input() const
tflite::RuntimeShape getTensorShape(const Tensor *tensor)