diff options
Diffstat (limited to 'compiler/nnsuite')
8 files changed, 15 insertions, 18 deletions
diff --git a/compiler/nnsuite/conv/model/src/RandomModel.cpp b/compiler/nnsuite/conv/model/src/RandomModel.cpp index 7b15d4c96..6d4a6147d 100644 --- a/compiler/nnsuite/conv/model/src/RandomModel.cpp +++ b/compiler/nnsuite/conv/model/src/RandomModel.cpp @@ -28,8 +28,8 @@ namespace conv { RandomModel::RandomModel(int32_t seed) - : _ifm_shape{1, 8, 8}, _ifm_name{"ifm"}, _ofm_name{"ofm"}, _ofm_shape{2, 6, 6}, - _ker_buffer{kernel::Shape{2, 1, 3, 3}, kernel::NCHWLayout{}} + : _ifm_shape{1, 8, 8}, _ifm_name{"ifm"}, _ofm_name{"ofm"}, _ofm_shape{2, 6, 6}, + _ker_buffer{kernel::Shape{2, 1, 3, 3}, kernel::NCHWLayout{}} { std::default_random_engine gen{static_cast<uint32_t>(seed)}; std::normal_distribution<float> dist{0.0f, 1.0f}; diff --git a/compiler/nnsuite/conv/nnkit-caffe/CMakeLists.txt b/compiler/nnsuite/conv/nnkit-caffe/CMakeLists.txt index 6445cc6fb..7e860f874 100644 --- a/compiler/nnsuite/conv/nnkit-caffe/CMakeLists.txt +++ b/compiler/nnsuite/conv/nnkit-caffe/CMakeLists.txt @@ -9,7 +9,6 @@ list(REMOVE_ITEM SOURCES ${TESTS}) add_library(nnsuite_conv_caffe SHARED ${SOURCES}) target_link_libraries(nnsuite_conv_caffe nnsuite_conv) target_link_libraries(nnsuite_conv_caffe nnkit_support_caffe) -target_link_libraries(nnsuite_conv_caffe stdex) nnas_find_package(GTest QUIET) diff --git a/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.cpp b/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.cpp index 31d2b33fc..664ca94f3 100644 --- a/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.cpp +++ b/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.cpp @@ -23,9 +23,9 @@ #include <nncc/core/ADT/kernel/Overlay.h> #include <nncc/core/ADT/kernel/NCHWLayout.h> -#include <stdex/Memory.h> +#include <memory> -using stdex::make_unique; +using std::make_unique; std::unique_ptr<nnkit::Backend> ConvBackend::create(const nnsuite::conv::Model &model) { diff --git a/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.test.cpp b/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.test.cpp index 776bf186b..20c42385a 100644 --- a/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.test.cpp +++ b/compiler/nnsuite/conv/nnkit-caffe/ConvBackend.test.cpp @@ -35,8 +35,8 @@ public: TestModel(const std::string &ifm_name, const feature::Shape &ifm_shape, const std::string &ofm_name, const feature::Shape &ofm_shape, const kernel::Shape &ker_shape, const kernel::Layout &ker_layout, float *ker_data) - : _ifm_name(ifm_name), _ifm_shape(ifm_shape), _ofm_name(ofm_name), _ofm_shape(ofm_shape), - _ker{ker_shape, ker_layout, ker_data} + : _ifm_name(ifm_name), _ifm_shape(ifm_shape), _ofm_name(ofm_name), + _ofm_shape(ofm_shape), _ker{ker_shape, ker_layout, ker_data} { // DO NOTHING } diff --git a/compiler/nnsuite/conv/nnkit-tflite/CMakeLists.txt b/compiler/nnsuite/conv/nnkit-tflite/CMakeLists.txt index c1cf88812..8e870490e 100644 --- a/compiler/nnsuite/conv/nnkit-tflite/CMakeLists.txt +++ b/compiler/nnsuite/conv/nnkit-tflite/CMakeLists.txt @@ -9,7 +9,6 @@ list(REMOVE_ITEM SOURCES ${TESTS}) add_library(nnsuite_conv_tflite SHARED ${SOURCES}) target_link_libraries(nnsuite_conv_tflite nnsuite_conv) target_link_libraries(nnsuite_conv_tflite nnkit_support_tflite-1.7) -target_link_libraries(nnsuite_conv_tflite stdex) nnas_find_package(GTest QUIET) diff --git a/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.cpp b/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.cpp index 8ec9ce491..ea189ff6e 100644 --- a/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.cpp +++ b/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.cpp @@ -74,7 +74,7 @@ static inline std::vector<int> as_dims(const nncc::core::ADT::kernel::Shape &sha } ConvBackend::ConvBackend(const nnsuite::conv::Model &model) - : _ifm_name{model.ifm_name()}, _ofm_name{model.ofm_name()} + : _ifm_name{model.ifm_name()}, _ofm_name{model.ofm_name()} { using nncc::core::ADT::kernel::Overlay; using nncc::core::ADT::kernel::NHWCLayout; @@ -123,12 +123,12 @@ ConvBackend::ConvBackend(const nnsuite::conv::Model &model) as_dims(model.ifm_shape()), quantization); _interp.SetTensorParametersReadOnly( - 2, kTfLiteFloat32 /* type */, "kernel" /* name */, as_dims(model.ker_shape()), quantization, - reinterpret_cast<const char *>(_kernel.data()), _kernel.size() * sizeof(float)); + 2, kTfLiteFloat32 /* type */, "kernel" /* name */, as_dims(model.ker_shape()), quantization, + reinterpret_cast<const char *>(_kernel.data()), _kernel.size() * sizeof(float)); _interp.SetTensorParametersReadOnly( - 3, kTfLiteFloat32 /* type */, "bias" /* name */, {static_cast<int>(_bias.size())}, - quantization, reinterpret_cast<const char *>(_bias.data()), _bias.size() * sizeof(float)); + 3, kTfLiteFloat32 /* type */, "bias" /* name */, {static_cast<int>(_bias.size())}, quantization, + reinterpret_cast<const char *>(_bias.data()), _bias.size() * sizeof(float)); auto param = typed_malloc<TfLiteConvParams>(); diff --git a/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.test.cpp b/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.test.cpp index db82f0cf9..98ac78fc2 100644 --- a/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.test.cpp +++ b/compiler/nnsuite/conv/nnkit-tflite/ConvBackend.test.cpp @@ -38,8 +38,8 @@ public: TestModel(const std::string &ifm_name, const feature::Shape &ifm_shape, const std::string &ofm_name, const feature::Shape &ofm_shape, const kernel::Shape &ker_shape, const kernel::Layout &ker_layout, float *ker_data) - : _ifm_name(ifm_name), _ifm_shape(ifm_shape), _ofm_name(ofm_name), _ofm_shape(ofm_shape), - _ker{ker_shape, ker_layout, ker_data} + : _ifm_name(ifm_name), _ifm_shape(ifm_shape), _ofm_name(ofm_name), + _ofm_shape(ofm_shape), _ker{ker_shape, ker_layout, ker_data} { // DO NOTHING } diff --git a/compiler/nnsuite/conv/nnkit-tflite/Entry.cpp b/compiler/nnsuite/conv/nnkit-tflite/Entry.cpp index 2c84f72e6..c1e013767 100644 --- a/compiler/nnsuite/conv/nnkit-tflite/Entry.cpp +++ b/compiler/nnsuite/conv/nnkit-tflite/Entry.cpp @@ -21,8 +21,7 @@ #include <nnkit/Backend.h> #include <nnkit/CmdlineArguments.h> -#include <stdex/Memory.h> - +#include <memory> #include <chrono> #include <iostream> @@ -40,5 +39,5 @@ extern "C" std::unique_ptr<nnkit::Backend> make_backend(const nnkit::CmdlineArgu const nnsuite::conv::RandomModel model{seed}; - return stdex::make_unique<ConvBackend>(model); + return std::make_unique<ConvBackend>(model); } |