Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle
提交
9353bc58
P
Paddle
项目概览
PaddlePaddle
/
Paddle
大约 1 年 前同步成功
通知
2298
Star
20931
Fork
5422
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1423
列表
看板
标记
里程碑
合并请求
543
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1,423
Issue
1,423
列表
看板
标记
里程碑
合并请求
543
合并请求
543
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
9353bc58
编写于
1月 21, 2019
作者:
T
Tao Luo
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
remove legacy MOBILE_INFERENCE option
上级
b4ccae75
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
20 addition
and
65 deletion
+20
-65
CMakeLists.txt
CMakeLists.txt
+1
-9
cmake/external/cares.cmake
cmake/external/cares.cmake
+1
-1
cmake/external/grpc.cmake
cmake/external/grpc.cmake
+1
-1
cmake/external/gzstream.cmake
cmake/external/gzstream.cmake
+0
-4
cmake/external/protobuf.cmake
cmake/external/protobuf.cmake
+1
-14
cmake/external/snappy.cmake
cmake/external/snappy.cmake
+0
-4
cmake/external/snappystream.cmake
cmake/external/snappystream.cmake
+0
-4
cmake/external/warpctc.cmake
cmake/external/warpctc.cmake
+0
-4
cmake/generic.cmake
cmake/generic.cmake
+1
-7
cmake/inference_lib.cmake
cmake/inference_lib.cmake
+15
-17
未找到文件。
CMakeLists.txt
浏览文件 @
9353bc58
...
...
@@ -115,10 +115,6 @@ if(ANDROID OR IOS)
"Disable nGraph when cross-compiling for Android and iOS"
FORCE
)
set
(
WITH_GOLANG OFF CACHE STRING
"Disable golang when cross-compiling for Android and iOS"
FORCE
)
# Compile PaddlePaddle mobile inference library
set
(
MOBILE_INFERENCE ON
)
add_definitions
(
-DPADDLE_MOBILE_INFERENCE
)
endif
()
if
(
APPLE
)
...
...
@@ -142,11 +138,7 @@ set(FLUID_INSTALL_DIR "${CMAKE_BINARY_DIR}/fluid_install_dir" CACHE STRING
set
(
FLUID_INFERENCE_INSTALL_DIR
"
${
CMAKE_BINARY_DIR
}
/fluid_inference_install_dir"
CACHE STRING
"A path setting fluid inference shared and static libraries"
)
if
(
MOBILE_INFERENCE
)
set
(
THIRD_PARTY_BUILD_TYPE MinSizeRel
)
else
()
set
(
THIRD_PARTY_BUILD_TYPE Release
)
endif
()
set
(
THIRD_PARTY_BUILD_TYPE Release
)
set
(
WITH_MKLML
${
WITH_MKL
}
)
if
(
NOT DEFINED WITH_MKLDNN
)
...
...
cmake/external/cares.cmake
浏览文件 @
9353bc58
...
...
@@ -13,7 +13,7 @@
# limitations under the License.
#
IF
(
MOBILE_INFERENCE OR
NOT WITH_DISTRIBUTE
)
IF
(
NOT WITH_DISTRIBUTE
)
return
()
ENDIF
()
...
...
cmake/external/grpc.cmake
浏览文件 @
9353bc58
...
...
@@ -13,7 +13,7 @@
# limitations under the License.
#
IF
(
MOBILE_INFERENCE OR
NOT WITH_DISTRIBUTE
)
IF
(
NOT WITH_DISTRIBUTE
)
return
()
ENDIF
()
...
...
cmake/external/gzstream.cmake
浏览文件 @
9353bc58
...
...
@@ -13,10 +13,6 @@
# limitations under the License.
#
IF
(
MOBILE_INFERENCE
)
return
()
ENDIF
()
include
(
ExternalProject
)
# NOTE: gzstream is needed when linking with ctr reader.
...
...
cmake/external/protobuf.cmake
浏览文件 @
9353bc58
...
...
@@ -204,15 +204,6 @@ FUNCTION(build_protobuf TARGET_NAME BUILD_FOR_HOST)
SET
(
PROTOBUF_REPO
"https://github.com/google/protobuf.git"
)
SET
(
PROTOBUF_TAG
"9f75c5aa851cd877fb0d93ccc31b8567a6706546"
)
IF
(
MOBILE_INFERENCE
)
# The reason why the official version is not used is described in
# https://github.com/PaddlePaddle/Paddle/issues/6114
SET
(
PROTOBUF_REPO
"https://github.com/qingqing01/protobuf.git"
)
SET
(
PROTOBUF_TAG
"v3.2.0"
)
IF
(
NOT BUILD_FOR_HOST
)
SET
(
OPTIONAL_ARGS
${
OPTIONAL_ARGS
}
"-Dprotobuf_BUILD_PROTOC_BINARIES=OFF"
)
ENDIF
()
ENDIF
()
ExternalProject_Add
(
${
TARGET_NAME
}
...
...
@@ -240,11 +231,7 @@ FUNCTION(build_protobuf TARGET_NAME BUILD_FOR_HOST)
)
ENDFUNCTION
()
IF
(
NOT MOBILE_INFERENCE
)
SET
(
PROTOBUF_VERSION 3.1
)
ELSE
()
SET
(
PROTOBUF_VERSION 3.2
)
ENDIF
()
SET
(
PROTOBUF_VERSION 3.1
)
IF
(
CMAKE_CROSSCOMPILING
)
build_protobuf
(
protobuf_host TRUE
)
LIST
(
APPEND external_project_dependencies protobuf_host
)
...
...
cmake/external/snappy.cmake
浏览文件 @
9353bc58
...
...
@@ -12,10 +12,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
if
(
MOBILE_INFERENCE OR RPI
)
return
()
endif
()
include
(
ExternalProject
)
# NOTE: snappy is needed when linking with recordio
...
...
cmake/external/snappystream.cmake
浏览文件 @
9353bc58
...
...
@@ -12,10 +12,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
IF
(
MOBILE_INFERENCE OR RPI
)
return
()
ENDIF
()
include
(
ExternalProject
)
set
(
SNAPPYSTREAM_SOURCES_DIR
${
THIRD_PARTY_PATH
}
/snappy_stream
)
...
...
cmake/external/warpctc.cmake
浏览文件 @
9353bc58
...
...
@@ -12,10 +12,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
IF
(
MOBILE_INFERENCE
)
return
()
ENDIF
()
INCLUDE
(
ExternalProject
)
SET
(
WARPCTC_SOURCES_DIR
${
THIRD_PARTY_PATH
}
/warpctc
)
...
...
cmake/generic.cmake
浏览文件 @
9353bc58
...
...
@@ -655,12 +655,6 @@ function(paddle_protobuf_generate_cpp SRCS HDRS)
set
(
${
SRCS
}
)
set
(
${
HDRS
}
)
if
(
MOBILE_INFERENCE
)
set
(
EXTRA_FLAG
"lite:"
)
else
()
set
(
EXTRA_FLAG
""
)
endif
()
foreach
(
FIL
${
ARGN
}
)
get_filename_component
(
ABS_FIL
${
FIL
}
ABSOLUTE
)
get_filename_component
(
FIL_WE
${
FIL
}
NAME_WE
)
...
...
@@ -677,7 +671,7 @@ function(paddle_protobuf_generate_cpp SRCS HDRS)
COMMAND
${
CMAKE_COMMAND
}
-E make_directory
"
${
CMAKE_CURRENT_BINARY_DIR
}
"
COMMAND
${
PROTOBUF_PROTOC_EXECUTABLE
}
-I
${
CMAKE_CURRENT_SOURCE_DIR
}
--cpp_out
"
${
EXTRA_FLAG
}${
CMAKE_CURRENT_BINARY_DIR
}
"
${
ABS_FIL
}
--cpp_out
"
${
CMAKE_CURRENT_BINARY_DIR
}
"
${
ABS_FIL
}
DEPENDS
${
ABS_FIL
}
protoc
COMMENT
"Running C++ protocol buffer compiler on
${
FIL
}
"
VERBATIM
)
...
...
cmake/inference_lib.cmake
浏览文件 @
9353bc58
...
...
@@ -149,25 +149,23 @@ if (WITH_NGRAPH)
)
endif
()
if
(
NOT MOBILE_INFERENCE AND NOT RPI
)
set
(
dst_dir
"
${
FLUID_INSTALL_DIR
}
/third_party/install/snappy"
)
copy
(
snappy_lib
SRCS
${
SNAPPY_INCLUDE_DIR
}
${
SNAPPY_LIBRARIES
}
DSTS
${
dst_dir
}
${
dst_dir
}
/lib
DEPS snappy
)
set
(
dst_dir
"
${
FLUID_INSTALL_DIR
}
/third_party/install/snappy"
)
copy
(
snappy_lib
SRCS
${
SNAPPY_INCLUDE_DIR
}
${
SNAPPY_LIBRARIES
}
DSTS
${
dst_dir
}
${
dst_dir
}
/lib
DEPS snappy
)
set
(
dst_dir
"
${
FLUID_INSTALL_DIR
}
/third_party/install/snappystream"
)
copy
(
snappystream_lib
SRCS
${
SNAPPYSTREAM_INCLUDE_DIR
}
${
SNAPPYSTREAM_LIBRARIES
}
DSTS
${
dst_dir
}
${
dst_dir
}
/lib
DEPS snappystream
)
set
(
dst_dir
"
${
FLUID_INSTALL_DIR
}
/third_party/install/snappystream"
)
copy
(
snappystream_lib
SRCS
${
SNAPPYSTREAM_INCLUDE_DIR
}
${
SNAPPYSTREAM_LIBRARIES
}
DSTS
${
dst_dir
}
${
dst_dir
}
/lib
DEPS snappystream
)
set
(
dst_dir
"
${
FLUID_INSTALL_DIR
}
/third_party/install/zlib"
)
copy
(
zlib_lib
SRCS
${
ZLIB_INCLUDE_DIR
}
${
ZLIB_LIBRARIES
}
DSTS
${
dst_dir
}
${
dst_dir
}
/lib
DEPS zlib
)
endif
()
set
(
dst_dir
"
${
FLUID_INSTALL_DIR
}
/third_party/install/zlib"
)
copy
(
zlib_lib
SRCS
${
ZLIB_INCLUDE_DIR
}
${
ZLIB_LIBRARIES
}
DSTS
${
dst_dir
}
${
dst_dir
}
/lib
DEPS zlib
)
# paddle fluid module
set
(
src_dir
"
${
PADDLE_SOURCE_DIR
}
/paddle/fluid"
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录