Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NPU] update npu ut skil scirpts, test=develop #35360

Merged
merged 5 commits into from
Sep 3, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions paddle/scripts/paddle_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1703,11 +1703,13 @@ set -x

function parallel_test_base_npu() {
# skipping if no NPU related files changed
if [ ${SKIL_NPU_TEST:-ON} == "ON" ] ; then
npu_cc_files=$(git diff --name-only ${BRANCH} | grep "op_npu.cc" | wc -l)
npu_py_files=$(git diff --name-only ${BRANCH} | grep "python/paddle/fluid/tests/unittests/npu" | wc -l)
if [ "${npu_cc_files}" -eq 0 ] && [ "${npu_py_files}" -eq 0 ] ; then
echo "NO NPU operators files changed, skip NPU unit tests"
if [ ${SKIP_NPU_TEST:-ON} == "ON" ] ; then
fetch_upstream_develop_if_not_exist
git diff --name-only remotes/upstream/$BRANCH
npu_cc_changes=$(git diff --name-only remotes/upstream/$BRANCH | grep "op_npu.cc" || true)
npu_py_changes=$(git diff --name-only remotes/upstream/$BRANCH | grep "op_npu.py" || true)
if [ -z "${npu_cc_changes}" ] && [ -z "${npu_py_changes}" ] ; then
echo "NO NPU operators files changed, skip NPU unit tests!"
exit 0
fi
fi
Expand Down