Browse Source

codecheck clean

pull/446/head
isaacxr 4 years ago
parent
commit
069dac4ea8
20 changed files with 4 additions and 57 deletions
  1. +1
    -0
      parser/caffe/caffe_parser.h
  2. +1
    -1
      parser/common/acl_graph_parser_util.h
  3. +0
    -5
      parser/common/op_def/arg_op.cc
  4. +0
    -2
      parser/common/op_def/arg_op.h
  5. +0
    -5
      parser/common/op_def/constant_op.cc
  6. +0
    -1
      parser/common/op_def/constant_op.h
  7. +0
    -6
      parser/common/op_def/frameworkop_op.cc
  8. +0
    -2
      parser/common/op_def/frameworkop_op.h
  9. +0
    -5
      parser/common/op_def/no_op_op.cc
  10. +0
    -2
      parser/common/op_def/no_op_op.h
  11. +1
    -1
      parser/common/op_def/operator.h
  12. +0
    -5
      parser/common/op_def/ref_switch_op.cc
  13. +0
    -2
      parser/common/op_def/ref_switch_op.h
  14. +0
    -5
      parser/common/op_def/shape_n_op.cc
  15. +0
    -2
      parser/common/op_def/shape_n_op.h
  16. +0
    -5
      parser/common/op_def/var_is_initialized_op_op.cc
  17. +0
    -1
      parser/common/op_def/var_is_initialized_op_op.h
  18. +0
    -5
      parser/common/op_def/variable_op.cc
  19. +0
    -2
      parser/common/op_def/variable_op.h
  20. +1
    -0
      parser/onnx/subgraph_adapter/subgraph_adapter_factory.h

+ 1
- 0
parser/caffe/caffe_parser.h View File

@@ -50,6 +50,7 @@ using std::set;
using std::string;
using std::unordered_map;
using std::vector;
using domi::Status;
static std::map<std::vector<std::string>, std::vector<std::string>> params_share_map;

class PARSER_FUNC_VISIBILITY CaffeModelParser : public domi::ModelParser {


+ 1
- 1
parser/common/acl_graph_parser_util.h View File

@@ -157,7 +157,7 @@ bool ValidateStr(const std::string &filePath, const std::string &mode);
std::string CurrentTimeInStr();

template <typename T, typename... Args>
static inline std::shared_ptr<T> MakeShared(Args &&... args) {
inline std::shared_ptr<T> MakeShared(Args &&... args) {
using T_nc = typename std::remove_const<T>::type;
std::shared_ptr<T> ret(new (std::nothrow) T_nc(std::forward<Args>(args)...));
return ret;


+ 0
- 5
parser/common/op_def/arg_op.cc View File

@@ -23,11 +23,6 @@ FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ArgOpOperator::ArgOpOperator()

ArgOpOperator::~ArgOpOperator() {}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ArgOpOperator &ArgOpOperator::Name(const std::string &name) {
(void)ParserOperator::Name(name);
return *this;
}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ArgOpOperator &ArgOpOperator::Index(int64_t index) {
Attr("index", static_cast<int64_t>(index));



+ 0
- 2
parser/common/op_def/arg_op.h View File

@@ -25,8 +25,6 @@ class ArgOpOperator : public ParserOperator {

~ArgOpOperator() override;

ArgOpOperator &Name(const std::string &name);

ArgOpOperator &Index(int64_t index);

int64_t GetIndex() const;


+ 0
- 5
parser/common/op_def/constant_op.cc View File

@@ -25,11 +25,6 @@ FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ConstantOperator::ConstantOpera

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ConstantOperator::~ConstantOperator() {}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ConstantOperator &ConstantOperator::Name(const std::string &name) {
ParserOperator::Name(name);
return *this;
}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY ConstantOperator &ConstantOperator::VectorAttr(
std::string key, std::vector<int64_t> &value) {
Attr(key, value);


+ 0
- 1
parser/common/op_def/constant_op.h View File

@@ -26,7 +26,6 @@ class ConstantOperator : public ParserOperator {
ConstantOperator();
~ConstantOperator() override;

ConstantOperator &Name(const std::string &name);
ConstantOperator &VectorAttr(std::string key, std::vector<int64_t> &value);

ConstantOperator &DType(ge::DataType t);


+ 0
- 6
parser/common/op_def/frameworkop_op.cc View File

@@ -24,12 +24,6 @@ FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY FrameworkOpOperator::FrameworkO

FrameworkOpOperator::~FrameworkOpOperator() {}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY FrameworkOpOperator &FrameworkOpOperator::Name(
const std::string &name) {
ParserOperator::Name(name);
return *this;
}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY FrameworkOpOperator &FrameworkOpOperator::Index(int64_t index) {
Attr(RETVAL_ATTR_NAME_INDEX, static_cast<int64_t>(index));
return *this;


+ 0
- 2
parser/common/op_def/frameworkop_op.h View File

@@ -26,8 +26,6 @@ class FrameworkOpOperator : public ParserOperator {

~FrameworkOpOperator() override;

FrameworkOpOperator &Name(const std::string &name);

FrameworkOpOperator &OriginalType(const std::string &type);

FrameworkOpOperator &NodeDefPkg(const std::string &nodedef_pkg);


+ 0
- 5
parser/common/op_def/no_op_op.cc View File

@@ -22,9 +22,4 @@ namespace ge {
FMK_FUNC_HOST_VISIBILITY NoOpOperator::NoOpOperator() : ParserOperator("NoOp") {}

FMK_FUNC_HOST_VISIBILITY NoOpOperator::~NoOpOperator() {}

FMK_FUNC_HOST_VISIBILITY NoOpOperator &NoOpOperator::Name(const std::string &name) {
ParserOperator::Name(name);
return *this;
}
} // namespace ge

+ 0
- 2
parser/common/op_def/no_op_op.h View File

@@ -25,8 +25,6 @@ class NoOpOperator : public ParserOperator {
public:
NoOpOperator();
~NoOpOperator() override;

NoOpOperator &Name(const std::string &name);
};
} // namespace ge



+ 1
- 1
parser/common/op_def/operator.h View File

@@ -45,7 +45,7 @@ class FMK_FUNC_HOST_VISIBILITY ParserOperator {
ParserOperator &AttrVector(std::string key, std::vector<int32_t> &value);
ParserOperator &AttrVector(std::string key, std::vector<int64_t> &value);

ParserOperator &Name(const std::string &name);
virtual ParserOperator &Name(const std::string &name);

ParserOperator &Type(const std::string &type);



+ 0
- 5
parser/common/op_def/ref_switch_op.cc View File

@@ -22,11 +22,6 @@ FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY RefSwitchOperator::RefSwitchOpe

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY RefSwitchOperator::~RefSwitchOperator() {}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY RefSwitchOperator &RefSwitchOperator::Name(const std::string &name) {
ParserOperator::Name(name);
return *this;
}

FMK_FUNC_HOST_VISIBILITY FMK_FUNC_DEV_VISIBILITY RefSwitchOperator &RefSwitchOperator::T(ge::DataType t) {
Attr("T", (int64_t)t);
return *this;


+ 0
- 2
parser/common/op_def/ref_switch_op.h View File

@@ -25,8 +25,6 @@ class RefSwitchOperator : public ParserOperator {
public:
RefSwitchOperator();
~RefSwitchOperator() override;

RefSwitchOperator &Name(const std::string &name);
RefSwitchOperator &T(ge::DataType t);
};
} // namespace ge


+ 0
- 5
parser/common/op_def/shape_n_op.cc View File

@@ -24,11 +24,6 @@ FMK_FUNC_HOST_VISIBILITY ShapeNOperator::ShapeNOperator() : ParserOperator("Shap

FMK_FUNC_HOST_VISIBILITY ShapeNOperator::~ShapeNOperator() {}

FMK_FUNC_HOST_VISIBILITY ShapeNOperator &ShapeNOperator::Name(const std::string &name) {
ParserOperator::Name(name);
return *this;
}

FMK_FUNC_HOST_VISIBILITY ShapeNOperator &ShapeNOperator::N(int64_t n) {
Attr(SHAPEN_ATTR_N, n);
return *this;


+ 0
- 2
parser/common/op_def/shape_n_op.h View File

@@ -26,8 +26,6 @@ class ShapeNOperator : public ParserOperator {
ShapeNOperator();
~ShapeNOperator() override;

ShapeNOperator &Name(const std::string &name);

ShapeNOperator &N(int64_t n);
int64_t GetN() const;
ShapeNOperator &InType(ge::DataType t);


+ 0
- 5
parser/common/op_def/var_is_initialized_op_op.cc View File

@@ -24,11 +24,6 @@ VarIsInitializedOpOperator::VarIsInitializedOpOperator() : ParserOperator(ge::pa

VarIsInitializedOpOperator::~VarIsInitializedOpOperator() {}

VarIsInitializedOpOperator &VarIsInitializedOpOperator::Name(const std::string &name) {
ParserOperator::Name(name);
return *this;
}

VarIsInitializedOpOperator &VarIsInitializedOpOperator::VectorAttr(const std::string &key,
std::vector<int64_t> &value) {
Attr(key, value);


+ 0
- 1
parser/common/op_def/var_is_initialized_op_op.h View File

@@ -26,7 +26,6 @@ class VarIsInitializedOpOperator : public ParserOperator {
VarIsInitializedOpOperator();
~VarIsInitializedOpOperator() override;

VarIsInitializedOpOperator &Name(const std::string &name);
VarIsInitializedOpOperator &VectorAttr(const std::string &key, std::vector<int64_t> &value);
};
} // namespace ge


+ 0
- 5
parser/common/op_def/variable_op.cc View File

@@ -23,11 +23,6 @@ VariableOperator::VariableOperator() : ParserOperator(ge::parser::VARIABLE) {}

VariableOperator::~VariableOperator() {}

VariableOperator &VariableOperator::Name(const std::string &name) {
ParserOperator::Name(name);
return *this;
}

VariableOperator &VariableOperator::Container(const std::string &container) {
Attr(VAR_ATTR_CONTAINER, container);
return *this;


+ 0
- 2
parser/common/op_def/variable_op.h View File

@@ -27,8 +27,6 @@ class VariableOperator : public ParserOperator {
VariableOperator();
~VariableOperator() override;

VariableOperator &Name(const std::string &name);

VariableOperator &Container(const std::string &container);

VariableOperator &SharedName(const std::string &sharedname);


+ 1
- 0
parser/onnx/subgraph_adapter/subgraph_adapter_factory.h View File

@@ -32,6 +32,7 @@
#endif

#include <map>
#include <memory>
#include <functional>
#include "subgraph_adapter.h"



Loading…
Cancel
Save