[mir2loco] Change type of strides argument (#7178)
authorСергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 <s.barannikov@samsung.com>
Wed, 4 Sep 2019 15:36:31 +0000 (18:36 +0300)
committerAlexander Efimov/AI Tools Lab/./Samsung Electronics <a.efimov@samsung.com>
Wed, 4 Sep 2019 15:36:31 +0000 (18:36 +0300)
Change the type of `strides` argument of `Conv2D` and `DepthwiseConv2D` operations to `vector<int32_t>`.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
compiler/mir2loco/src/mir2loco.test.cpp

index 223fdd3..139f4db 100644 (file)
@@ -368,7 +368,7 @@ TEST_F(TestTransformer_mir2loco, Conv2D_Test)
   auto mir_tensor = mir::TensorVariant(mir::DataType::FLOAT32, shape, (const void *)data);
   auto *constant = mir_graph.create<mir::ops::ConstantOp>(mir_tensor)->getOutput(0);
   auto *conv = mir_graph
-                   .create<mir::ops::Conv2DOp>(input, constant, mir::Shape{2, 3},
+                   .create<mir::ops::Conv2DOp>(input, constant, std::vector<std::int32_t>{2, 3},
                                                std::vector<std::int32_t>{5, 9},
                                                std::vector<std::int32_t>{7, 4})
                    ->getOutput(0);
@@ -495,9 +495,9 @@ TEST_F(TestTransformer_mir2loco, DepthwiseConv2D_Test)
   auto mir_tensor = mir::TensorVariant(mir::DataType::FLOAT32, shape, (const void *)data);
   auto *constant = mir_graph.create<mir::ops::ConstantOp>(mir_tensor)->getOutput(0);
   auto *conv = mir_graph
-                   .create<mir::ops::DepthwiseConv2DOp>(input, constant, mir::Shape{2, 3},
-                                                        std::vector<std::int32_t>{5, 9},
-                                                        std::vector<std::int32_t>{7, 4})
+                   .create<mir::ops::DepthwiseConv2DOp>(
+                       input, constant, std::vector<std::int32_t>{2, 3},
+                       std::vector<std::int32_t>{5, 9}, std::vector<std::int32_t>{7, 4})
                    ->getOutput(0);
   mir_graph.create<mir::ops::OutputOp>(conv);
   input->setName("x");