Skip to content

Commit 3420c94

Browse files
committed
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into fix_python35_CI_random_fail
2 parents d4accfa + b805751 commit 3420c94

File tree

239 files changed

+4807
-2470
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

239 files changed

+4807
-2470
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ RUN curl -s -q https://glide.sh/get | sh
5353
# and its size is only one-third of the official one.
5454
# 2. Manually add ~IPluginFactory() in IPluginFactory class of NvInfer.h, otherwise, it couldn't work in paddle.
5555
# See https://github.com/PaddlePaddle/Paddle/issues/10129 for details.
56-
RUN wget -qO- http://paddlepaddledeps.bj.bcebos.com/TensorRT-4.0.0.3.Ubuntu-16.04.4.x86_64-gnu.cuda-8.0.cudnn7.0.tar.gz | \
56+
RUN wget -qO- http://paddlepaddledeps.cdn.bcebos.com/TensorRT-4.0.0.3.Ubuntu-16.04.4.x86_64-gnu.cuda-8.0.cudnn7.0.tar.gz | \
5757
tar -xz -C /usr/local && \
5858
cp -rf /usr/local/TensorRT/include /usr && \
5959
cp -rf /usr/local/TensorRT/lib /usr

README.md

Lines changed: 7 additions & 14 deletions

cmake/cuda.cmake

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,14 +169,19 @@ set(CUDA_PROPAGATE_HOST_FLAGS OFF)
169169

170170
# Release/Debug flags set by cmake. Such as -O3 -g -DNDEBUG etc.
171171
# So, don't set these flags here.
172+
if (NOT WIN32) # windows msvc2015 support c++11 natively.
173+
# -std=c++11 -fPIC not recoginize by msvc, -Xcompiler will be added by cmake.
172174
list(APPEND CUDA_NVCC_FLAGS "-std=c++11")
173-
list(APPEND CUDA_NVCC_FLAGS "--use_fast_math")
174175
list(APPEND CUDA_NVCC_FLAGS "-Xcompiler -fPIC")
176+
endif(NOT WIN32)
177+
178+
list(APPEND CUDA_NVCC_FLAGS "--use_fast_math")
175179
# in cuda9, suppress cuda warning on eigen
176180
list(APPEND CUDA_NVCC_FLAGS "-w")
177181
# Set :expt-relaxed-constexpr to suppress Eigen warnings
178182
list(APPEND CUDA_NVCC_FLAGS "--expt-relaxed-constexpr")
179183

184+
if (NOT WIN32)
180185
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
181186
list(APPEND CUDA_NVCC_FLAGS ${CMAKE_CXX_FLAGS_DEBUG})
182187
elseif(CMAKE_BUILD_TYPE STREQUAL "Release")
@@ -187,6 +192,13 @@ elseif(CMAKE_BUILD_TYPE STREQUAL "MinSizeRel")
187192
# nvcc 9 does not support -Os. Use Release flags instead
188193
list(APPEND CUDA_NVCC_FLAGS ${CMAKE_CXX_FLAGS_RELEASE})
189194
endif()
195+
else(NOT WIN32)
196+
if(CMAKE_BUILD_TYPE STREQUAL "Release")
197+
list(APPEND CUDA_NVCC_FLAGS "-O3 -DNDEBUG")
198+
else()
199+
message(FATAL "Windows only support Release build now. Please set visual studio build type to Release, x64 build.")
200+
endif()
201+
endif(NOT WIN32)
190202

191203
mark_as_advanced(CUDA_BUILD_CUBIN CUDA_BUILD_EMULATION CUDA_VERBOSE_BUILD)
192204
mark_as_advanced(CUDA_SDK_ROOT_DIR CUDA_SEPARABLE_COMPILATION)

cmake/external/grpc.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ ExternalProject_Add(
4444
# 3. keep only zlib, cares, protobuf, boringssl under "third_party",
4545
# checkout and clean other dirs under third_party
4646
# 4. remove .git, and package the directory.
47-
URL "http://paddlepaddledeps.bj.bcebos.com/grpc-v1.10.x.tar.gz"
47+
URL "http://paddlepaddledeps.cdn.bcebos.com/grpc-v1.10.x.tar.gz"
4848
URL_MD5 "1f268a2aff6759839dccd256adcc91cf"
4949
PREFIX ${GRPC_SOURCES_DIR}
5050
UPDATE_COMMAND ""

cmake/inference_lib.cmake

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -128,16 +128,13 @@ set(src_dir "${PADDLE_SOURCE_DIR}/paddle/fluid")
128128
set(dst_dir "${FLUID_INSTALL_DIR}/paddle/fluid")
129129
set(module "framework")
130130
if (NOT WIN32)
131-
copy(framework_lib DEPS framework_py_proto
132-
SRCS ${src_dir}/${module}/*.h ${src_dir}/${module}/details/*.h ${PADDLE_BINARY_DIR}/paddle/fluid/framework/framework.pb.h
133-
DSTS ${dst_dir}/${module} ${dst_dir}/${module}/details ${dst_dir}/${module}
134-
)
135-
else()
136-
copy(framework_lib
131+
set(framework_lib_deps framework_py_proto)
132+
endif(NOT WIN32)
133+
copy(framework_lib DEPS ${framework_lib_deps}
137134
SRCS ${src_dir}/${module}/*.h ${src_dir}/${module}/details/*.h ${PADDLE_BINARY_DIR}/paddle/fluid/framework/framework.pb.h
138-
DSTS ${dst_dir}/${module} ${dst_dir}/${module}/details ${dst_dir}/${module}
135+
${src_dir}/${module}/ir/*.h
136+
DSTS ${dst_dir}/${module} ${dst_dir}/${module}/details ${dst_dir}/${module} ${dst_dir}/${module}/ir
139137
)
140-
endif(NOT WIN32)
141138

142139
set(module "memory")
143140
copy(memory_lib
@@ -161,7 +158,8 @@ set(module "inference")
161158
copy(inference_lib DEPS ${inference_deps}
162159
SRCS ${src_dir}/${module}/*.h ${PADDLE_BINARY_DIR}/paddle/fluid/inference/libpaddle_fluid.*
163160
${src_dir}/${module}/api/paddle_inference_api.h ${src_dir}/${module}/api/demo_ci
164-
DSTS ${dst_dir}/${module} ${dst_dir}/${module} ${dst_dir}/${module} ${dst_dir}/${module}
161+
${PADDLE_BINARY_DIR}/paddle/fluid/inference/api/paddle_inference_pass.h
162+
DSTS ${dst_dir}/${module} ${dst_dir}/${module} ${dst_dir}/${module} ${dst_dir}/${module} ${dst_dir}/${module}
165163
)
166164

167165
set(module "platform")

doc/fluid/new_docs/advanced_usage/deploy/index_anakin.rst

Lines changed: 2 additions & 2 deletions

doc/fluid/new_docs/advanced_usage/deploy/index_native.rst

Lines changed: 0 additions & 8 deletions
This file was deleted.

doc/fluid/new_docs/advanced_usage/index.rst

Lines changed: 0 additions & 1 deletion
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
*.pyc
2+
train.log
3+
output
4+
data/cifar-10-batches-py/
5+
data/cifar-10-python.tar.gz
6+
data/*.txt
7+
data/*.list
8+
data/mean.meta

doc/fluid/new_docs/beginners_guide/basics/image_classification/README.cn.md

Lines changed: 13 additions & 13 deletions

0 commit comments

Comments
 (0)