This commit adds 'Output' class which records informations related with
a network's output.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
--- /dev/null
+#ifndef __COCO_IR_OUTPUT_H__
+#define __COCO_IR_OUTPUT_H__
+
+#include <nncc/core/ADT/tensor/Shape.h>
+
+namespace coco
+{
+
+class Output
+{
+public:
+ Output(const nncc::core::ADT::tensor::Shape &shape);
+
+public:
+ const nncc::core::ADT::tensor::Shape &shape(void) const { return _shape; }
+
+private:
+ nncc::core::ADT::tensor::Shape const _shape;
+};
+
+} // namespace coco
+
+#endif // __COCO_IR_OUTPUT_H__
--- /dev/null
+#include "coco/IR/Output.h"
+
+namespace coco
+{
+
+Output::Output(const nncc::core::ADT::tensor::Shape &shape) : _shape{shape}
+{
+ // DO NOTHING
+}
+
+} // namespace coco
--- /dev/null
+#include "coco/IR/Output.h"
+
+#include <gtest/gtest.h>
+
+TEST(IR_OUTPUT, ctor_should_set_shape)
+{
+ const nncc::core::ADT::tensor::Shape shape{1, 3, 3, 1};
+ coco::Output output{shape};
+
+ ASSERT_EQ(output.shape(), shape);
+}