@@ -54,7 +54,7 @@ namespace tf = tensorflow;
5454 *
5555 * @return tf::SavedModelBundleLite SavedModel
5656 */
57- tf::SavedModelBundleLite loadSavedModel (
57+ inline tf::SavedModelBundleLite loadSavedModel (
5858 const std::string& dir, const bool allow_growth = true ,
5959 const double per_process_gpu_memory_fraction = 0 ,
6060 const std::string& visible_device_list = " " ) {
@@ -82,7 +82,7 @@ tf::SavedModelBundleLite loadSavedModel(
8282 *
8383 * @return tf::Session* session
8484 */
85- tf::Session* loadSavedModelIntoNewSession (
85+ inline tf::Session* loadSavedModelIntoNewSession (
8686 const std::string& dir, const bool allow_growth = true ,
8787 const double per_process_gpu_memory_fraction = 0 ,
8888 const std::string& visible_device_list = " " ) {
@@ -102,7 +102,7 @@ tf::Session* loadSavedModelIntoNewSession(
102102 *
103103 * @return tf::Session* session
104104 */
105- tf::Session* getSessionFromSavedModel (
105+ inline tf::Session* getSessionFromSavedModel (
106106 const tf::SavedModelBundleLite& saved_model) {
107107
108108 return saved_model.GetSession ();
@@ -121,7 +121,7 @@ tf::Session* getSessionFromSavedModel(
121121 *
122122 * @return std::string node name
123123 */
124- std::string getSavedModelNodeByLayerName (
124+ inline std::string getSavedModelNodeByLayerName (
125125 const tf::SavedModelBundleLite& saved_model, const std::string& layer_name,
126126 const std::string& signature = " serving_default" ) {
127127
@@ -156,7 +156,7 @@ std::string getSavedModelNodeByLayerName(
156156 *
157157 * @return std::string layer name
158158 */
159- std::string getSavedModelLayerByNodeName (
159+ inline std::string getSavedModelLayerByNodeName (
160160 const tf::SavedModelBundleLite& saved_model, const std::string& node_name,
161161 const std::string& signature = " serving_default" ) {
162162
@@ -195,7 +195,7 @@ std::string getSavedModelLayerByNodeName(
195195 *
196196 * @return std::vector<std::string> input names
197197 */
198- std::vector<std::string> getSavedModelInputNames (
198+ inline std::vector<std::string> getSavedModelInputNames (
199199 const tf::SavedModelBundleLite& saved_model, const bool layer_names = false ,
200200 const std::string& signature = " serving_default" ) {
201201
@@ -236,7 +236,7 @@ std::vector<std::string> getSavedModelInputNames(
236236 *
237237 * @return std::vector<std::string> output names
238238 */
239- std::vector<std::string> getSavedModelOutputNames (
239+ inline std::vector<std::string> getSavedModelOutputNames (
240240 const tf::SavedModelBundleLite& saved_model, const bool layer_names = false ,
241241 const std::string& signature = " serving_default" ) {
242242
@@ -270,7 +270,7 @@ std::vector<std::string> getSavedModelOutputNames(
270270 *
271271 * @return std::vector<int> node shape
272272 */
273- std::vector<int > getSavedModelNodeShape (
273+ inline std::vector<int > getSavedModelNodeShape (
274274 const tf::SavedModelBundleLite& saved_model, const std::string& node_name,
275275 const std::string& signature = " serving_default" ) {
276276
@@ -304,7 +304,7 @@ std::vector<int> getSavedModelNodeShape(
304304 *
305305 * @return tf::DataType node datatype
306306 */
307- tf::DataType getSavedModelNodeType (
307+ inline tf::DataType getSavedModelNodeType (
308308 const tf::SavedModelBundleLite& saved_model, const std::string& node_name,
309309 const std::string& signature = " serving_default" ) {
310310
@@ -337,7 +337,7 @@ tf::DataType getSavedModelNodeType(
337337 *
338338 * @return std::string formatted info message
339339 */
340- std::string getSavedModelInfoString (
340+ inline std::string getSavedModelInfoString (
341341 const tf::SavedModelBundleLite& saved_model) {
342342
343343 std::stringstream ss;
@@ -379,4 +379,4 @@ std::string getSavedModelInfoString(
379379}
380380
381381
382- } // namespace tensorflow_cpp
382+ } // namespace tensorflow_cpp
0 commit comments