diff --git a/tools/test_ci_model_benchmark.sh b/tools/test_ci_model_benchmark.sh index ae2d4458efdb1dad9a6aa66e17c759d16cb0d100..33d76dea2c5caebd40355627436c8b75d6bdfb33 100644 --- a/tools/test_ci_model_benchmark.sh +++ b/tools/test_ci_model_benchmark.sh @@ -20,18 +20,17 @@ function check_whl { [ $? -ne 0 ] && echo "build paddle failed." && exit 1 pip uninstall -y paddlepaddle_gpu pip install build/python/dist/*.whl - mkdir build/pr_whl && cp build/python/dist/*.whl build/pr_whl [ $? -ne 0 ] && echo "install paddle failed." && exit 1 - + mkdir build/pr_whl && cp build/python/dist/*.whl build/pr_whl mkdir -p /tmp/pr && mkdir -p /tmp/develop unzip -q build/python/dist/*.whl -d /tmp/pr rm -f build/python/dist/*.whl && rm -f build/python/build/.timestamp git checkout . git checkout -b develop_base_pr upstream/$BRANCH - bash -x paddle/scripts/paddle_build.sh build [ $? -ne 0 ] && echo "install paddle failed." && exit 1 cd build + make -j `nproc` unzip -q python/dist/*.whl -d /tmp/develop sed -i '/version.py/d' /tmp/pr/*/RECORD @@ -40,6 +39,7 @@ function check_whl { if [ ${diff_whl} -eq 0 ];then echo "paddle whl does not diff in PR-CI-Model-benchmark, so skip this ci" echo "ipipe_log_param_isSkipTest_model_benchmark: 1" + echo "cpu_benchmark=ON" >${cfs_dir}/model_benchmark/${AGILE_PULL_ID}/${AGILE_REVISION}/pass.txt exit 0 else echo "ipipe_log_param_isSkipTest_model_benchmark: 0" @@ -47,7 +47,7 @@ function check_whl { } function compile_install_paddle { - export CUDA_ARCH_NAME=Auto + export CUDA_ARCH_NAME=${CUDA_ARCH_NAME:-Auto} export PY_VERSION=3.7 export WITH_DISTRIBUTE=OFF export WITH_GPU=ON