20#include "kernels/Utils.h"
22#include <tensorflow/lite/kernels/internal/reference/reduce.h>
39 for (
int j = 0;
j <
i;
j++)
146 switch (
input()->element_type())
148 case DataType::FLOAT32:
152 throw std::runtime_error(
"luci-intp Sum Unsupported type.");
156void Sum::evalFloat()
const
170 tflite::reference_ops::ReduceGeneric<float>(
175 [](
const float current,
const float in) ->
float { return current + in; });
const std::vector< Tensor * > & getOutputTensors() const
const ReducerParams _params
int32_t num_elements() const
void resize(const Shape &new_shape)
const Shape & shape() const
Sum(const Tensor *input, const Tensor *axes, Tensor *output, Tensor *temp_index, Tensor *resolved_axes, const ReducerParams ¶ms)
void configure() override
const Tensor * axes() const
const Tensor * input() const
void execute() const override
#define LUCI_INTERPRETER_CHECK(cond)
const luci_interpreter::RuntimeShape output_shape
tflite::RuntimeShape getTensorShape(const Tensor *tensor)
T must_cast(loco::Node *node)