summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author박종현/On-Device Lab(SR)/Staff Engineer/삼성전자 <jh1302.park@samsung.com>2019-09-17 08:33:22 (GMT)
committerGitHub Enterprise <noreply-CODE@samsung.com>2019-09-17 08:33:22 (GMT)
commit670c01e57942bfce5cad41710ef6b70755e28fe6 (patch)
treec8d050bc2bd7df4c70221a1ef7a77b55700ae2a2
parentb1e12cf6012c371c5b88572e936e2512f142bbf2 (diff)
downloadnnfw-670c01e57942bfce5cad41710ef6b70755e28fe6.zip
nnfw-670c01e57942bfce5cad41710ef6b70755e28fe6.tar.gz
nnfw-670c01e57942bfce5cad41710ef6b70755e28fe6.tar.bz2
[plier-tf] Remove unnecessary const qualifier (#7513)
"const" qualifier on function return type has no effect. Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
-rw-r--r--compiler/plier-tf/include/plier/tf/Convert.h4
-rw-r--r--compiler/plier-tf/src/Convert.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/compiler/plier-tf/include/plier/tf/Convert.h b/compiler/plier-tf/include/plier/tf/Convert.h
index 857f32e..13e855d 100644
--- a/compiler/plier-tf/include/plier/tf/Convert.h
+++ b/compiler/plier-tf/include/plier/tf/Convert.h
@@ -60,9 +60,9 @@ enum class DataLayout
};
/// @ brief Convert TF Data Layout string (e.g., "NHWC") to enum class for programming convenience
-const DataLayout as_data_layout(const std::string &tf_layout_str);
+DataLayout as_data_layout(const std::string &tf_layout_str);
-const DataLayout get_data_layout(const tensorflow::NodeDef &node, const std::string &attr_name);
+DataLayout get_data_layout(const tensorflow::NodeDef &node, const std::string &attr_name);
/**
* @brief Copy shape defined in TensorShapeProto to angkor shape
diff --git a/compiler/plier-tf/src/Convert.cpp b/compiler/plier-tf/src/Convert.cpp
index 127c0bc..15fc2da 100644
--- a/compiler/plier-tf/src/Convert.cpp
+++ b/compiler/plier-tf/src/Convert.cpp
@@ -141,7 +141,7 @@ loco::DataType as_loco_datatype(const tensorflow::DataType tf_dtype)
throw std::runtime_error{"Unsupported tensorflow dtype: " + tensorflow::DataType_Name(tf_dtype)};
}
-const DataLayout as_data_layout(const std::string &tf_layout_str)
+DataLayout as_data_layout(const std::string &tf_layout_str)
{
if (tf_layout_str == "NHWC")
return DataLayout::NHWC;
@@ -151,7 +151,7 @@ const DataLayout as_data_layout(const std::string &tf_layout_str)
throw std::runtime_error("unknown data layout");
}
-const DataLayout get_data_layout(const tensorflow::NodeDef &node, const std::string &attr_name)
+DataLayout get_data_layout(const tensorflow::NodeDef &node, const std::string &attr_name)
{
auto layout = get_string_attr(node, attr_name);