Skip to content

Commit

Permalink
Merge pull request #9392 from putcn/fix-submit-local
Browse files Browse the repository at this point in the history
fix submit_local's paddle pip name issue
  • Loading branch information
luotao1 committed Mar 28, 2018
2 parents eb62a77 + f492575 commit ab41c5d
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions paddle/scripts/submit_local.sh.in
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,15 @@ if [ $? -ne 0 ]; then
exit 1
fi

INSTALLED_VERSION=`pip freeze 2>/dev/null | grep '^paddle' | sed 's/.*==//g'`
if [ "@WITH_GPU@" == "ON" ]; then
PADDLE_NAME="paddlepaddle-gpu"
else
PADDLE_NAME="paddlepaddle"
fi

INSTALLED_VERSION=`pip freeze 2>/dev/null | grep "^${PADDLE_NAME}==" | sed 's/.*==//g'`

if [ -z ${INSTALLED_VERSION} ]; then
if [ -z "${INSTALLED_VERSION}" ]; then
INSTALLED_VERSION="0.0.0" # not installed
fi
cat <<EOF | python -
Expand Down

0 comments on commit ab41c5d

Please sign in to comment.