[nnc core] Add reshape operation description (#392)
authorVladimir Plazun/AI Tools Lab /SRR/Engineer/삼성전자 <v.plazun@partner.samsung.com>
Fri, 29 Jun 2018 07:31:54 +0000 (11:31 +0400)
committerSergey Vostokov/AI Tools Lab /SRR/Staff Engineer/삼성전자 <s.vostokov@samsung.com>
Fri, 29 Jun 2018 07:31:54 +0000 (16:31 +0900)
This commit adds missing reshape operation description

Signed-off-by: Vladimir Plazun <v.plazun@partner.samsung.com>
contrib/nnc/libs/core/include/nnc/core/IR/model/operations/reshape_op.h [new file with mode: 0644]
contrib/nnc/libs/core/include/nnc/core/IR/model/visitor/visitor.h

diff --git a/contrib/nnc/libs/core/include/nnc/core/IR/model/operations/reshape_op.h b/contrib/nnc/libs/core/include/nnc/core/IR/model/operations/reshape_op.h
new file mode 100644 (file)
index 0000000..bf65492
--- /dev/null
@@ -0,0 +1,29 @@
+#pragma once
+
+#include "nnc/core/IR/model/operations/operation.h"
+
+namespace nncc
+{
+namespace contrib
+{
+namespace core
+{
+namespace IR
+{
+namespace model
+{
+namespace ops
+{
+
+class ReshapeOp : public OpDescription
+{
+public:
+  explicit ReshapeOp() : OpDescription(1, 1) {}
+};
+
+} // namespace ops
+} // namespace model
+} // namespace IR
+} // namespace core
+} // namespace contrib
+} // namespace nncc
index 0d16e83..189cd3c 100644 (file)
@@ -25,6 +25,7 @@ namespace ops
   class BiasAddOp;
   class VariableOp;
   class ReluOp;
+  class ReshapeOp;
 }
 
 class Visitor {
@@ -39,6 +40,7 @@ class Visitor {
   virtual void visit(ADT::INode *node, ops::BiasAddOp &op) = 0;
   virtual void visit(ADT::INode *node, ops::VariableOp &op) = 0;
   virtual void visit(ADT::INode *node, ops::ReluOp &op) = 0;
+  virtual void visit(ADT::INode* node, ops::ReshapeOp &op) = 0;
 
   virtual ~Visitor() = default;
 };