未验证 提交 8f94d349 编写于 作者: T tianshuo78520a 提交者: GitHub

Add cpu/gpu for PR-CI-CPU-Py2 (#35174)

* notest;test=cpu_gpu

* notest;test=cpu_gpu

* notest;test=cpu_gpu

* notest;test=cpu_gpu

* notest;test=cpu_gpu

* notest;test=cpu_gpu

* notest;test=cpu_gpu

* fix

* fix
上级 20cfa8ba
......@@ -732,8 +732,8 @@ function check_whl_size() {
dev_whl_size=`du -m ${PADDLE_ROOT}/build/python/dist/*.whl|awk '{print $1}'`
echo "dev_whl_size: ${dev_whl_size}"
whldiffSize=`expr ${pr_whl_size} - ${dev_whl_size}`
if [ ${whldiffSize} -gt 10 ] ; then
whldiffSize=`echo $(($pr_whl_size - $dev_whl_size))`
if [ ${whldiffSize} -gt 10 ]; then
approval_line=`curl -H "Authorization: token ${GITHUB_API_TOKEN}" https://api.github.com/repos/PaddlePaddle/Paddle/pulls/${GIT_PR_ID}/reviews?per_page=10000`
APPROVALS=`echo ${approval_line}|python ${PADDLE_ROOT}/tools/check_pr_approval.py 1 22334008 22361972`
echo "current pr ${GIT_PR_ID} got approvals: ${APPROVALS}"
......@@ -2351,6 +2351,31 @@ function main() {
assert_api_spec_approvals
check_whl_size
;;
build_and_check_cpu)
set +e
check_style_info=$(check_style)
check_style_code=$?
find_temporary_files
generate_upstream_develop_api_spec ${PYTHON_ABI:-""} ${parallel_number}
cmake_gen_and_build ${PYTHON_ABI:-""} ${parallel_number}
check_sequence_op_unittest
generate_api_spec ${PYTHON_ABI:-""} "PR"
check_whl_size
echo 11111,$?
;;
build_and_check_gpu)
set +e
example_info_gpu=""
example_code_gpu=0
if [ "${WITH_GPU}" == "ON" ] ; then
example_info_gpu=$(exec_samplecode_test gpu)
example_code_gpu=$?
fi
example_info=$(exec_samplecode_test cpu)
example_code=$?
summary_check_problems $check_style_code $[${example_code_gpu} + ${example_code}] "$check_style_info" "${example_info_gpu}\n${example_info}"
assert_api_spec_approvals
;;
build)
cmake_gen ${PYTHON_ABI:-""}
build ${parallel_number}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册