提交 caa448de 编写于 作者: D dongdaxiang

add debugger in paddle_serving_app

上级 c0a227ad
...@@ -85,6 +85,17 @@ include(generic) ...@@ -85,6 +85,17 @@ include(generic)
include(flags) include(flags)
endif() endif()
if (APP)
include(external/zlib)
include(external/boost)
include(external/protobuf)
include(external/gflags)
include(external/glog)
include(external/pybind11)
include(external/python)
include(generic)
endif()
if (SERVER) if (SERVER)
include(external/cudnn) include(external/cudnn)
include(paddlepaddle) include(paddlepaddle)
......
...@@ -23,6 +23,11 @@ add_subdirectory(pdcodegen) ...@@ -23,6 +23,11 @@ add_subdirectory(pdcodegen)
add_subdirectory(sdk-cpp) add_subdirectory(sdk-cpp)
endif() endif()
if (APP)
add_subdirectory(configure)
endif()
if(CLIENT) if(CLIENT)
add_subdirectory(general-client) add_subdirectory(general-client)
endif() endif()
......
if (SERVER OR CLIENT)
LIST(APPEND protofiles LIST(APPEND protofiles
${CMAKE_CURRENT_LIST_DIR}/proto/server_configure.proto ${CMAKE_CURRENT_LIST_DIR}/proto/server_configure.proto
${CMAKE_CURRENT_LIST_DIR}/proto/sdk_configure.proto ${CMAKE_CURRENT_LIST_DIR}/proto/sdk_configure.proto
...@@ -28,6 +29,7 @@ FILE(GLOB inc ${CMAKE_CURRENT_BINARY_DIR}/*.pb.h) ...@@ -28,6 +29,7 @@ FILE(GLOB inc ${CMAKE_CURRENT_BINARY_DIR}/*.pb.h)
install(FILES ${inc} install(FILES ${inc}
DESTINATION ${PADDLE_SERVING_INSTALL_DIR}/include/configure) DESTINATION ${PADDLE_SERVING_INSTALL_DIR}/include/configure)
endif()
py_proto_compile(general_model_config_py_proto SRCS proto/general_model_config.proto) py_proto_compile(general_model_config_py_proto SRCS proto/general_model_config.proto)
add_custom_target(general_model_config_py_proto_init ALL COMMAND ${CMAKE_COMMAND} -E touch __init__.py) add_custom_target(general_model_config_py_proto_init ALL COMMAND ${CMAKE_COMMAND} -E touch __init__.py)
...@@ -51,6 +53,14 @@ add_custom_command(TARGET general_model_config_py_proto POST_BUILD ...@@ -51,6 +53,14 @@ add_custom_command(TARGET general_model_config_py_proto POST_BUILD
endif() endif()
if (APP)
add_custom_command(TARGET general_model_config_py_proto POST_BUILD
COMMAND ${CMAKE_COMMAND} -E make_directory ${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app/proto
COMMAND cp *.py ${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app/proto
COMMENT "Copy generated general_model_config proto file into directory paddle_serving_app/proto."
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
endif()
if (SERVER) if (SERVER)
py_proto_compile(server_config_py_proto SRCS proto/server_configure.proto) py_proto_compile(server_config_py_proto SRCS proto/server_configure.proto)
add_custom_target(server_config_py_proto_init ALL COMMAND ${CMAKE_COMMAND} -E touch __init__.py) add_custom_target(server_config_py_proto_init ALL COMMAND ${CMAKE_COMMAND} -E touch __init__.py)
......
...@@ -16,3 +16,4 @@ from .reader.image_reader import ImageReader, File2Image, URL2Image, Sequential, ...@@ -16,3 +16,4 @@ from .reader.image_reader import ImageReader, File2Image, URL2Image, Sequential,
from .reader.lac_reader import LACReader from .reader.lac_reader import LACReader
from .reader.senta_reader import SentaReader from .reader.senta_reader import SentaReader
from .models import ServingModels from .models import ServingModels
from .local_predict import Debugger
...@@ -42,10 +42,11 @@ if '${PACK}' == 'ON': ...@@ -42,10 +42,11 @@ if '${PACK}' == 'ON':
REQUIRED_PACKAGES = [ REQUIRED_PACKAGES = [
'six >= 1.10.0', 'sentencepiece' 'six >= 1.10.0', 'sentencepiece', 'cv2', 'pillow'
] ]
packages=['paddle_serving_app', packages=['paddle_serving_app',
'paddle_serving_app.proto',
'paddle_serving_app.reader', 'paddle_serving_app.reader',
'paddle_serving_app.utils', 'paddle_serving_app.utils',
'paddle_serving_app.models', 'paddle_serving_app.models',
...@@ -54,6 +55,8 @@ packages=['paddle_serving_app', ...@@ -54,6 +55,8 @@ packages=['paddle_serving_app',
package_data={} package_data={}
package_dir={'paddle_serving_app': package_dir={'paddle_serving_app':
'${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app', '${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app',
'paddle_serving_app.proto':
'${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app/proto',
'paddle_serving_app.reader': 'paddle_serving_app.reader':
'${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app/reader', '${PADDLE_SERVING_BINARY_DIR}/python/paddle_serving_app/reader',
'paddle_serving_app.utils': 'paddle_serving_app.utils':
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册