Skip to content
Snippets Groups Projects
Unverified Commit 50f5d7a0 authored by i-robot's avatar i-robot Committed by Gitee
Browse files

!3101 fix run_distribute_train.sh for scop

Merge pull request !3101 from 185******25/master
parents 9d78f770 6a1352e1
No related branches found
No related tags found
No related merge requests found
......@@ -16,7 +16,7 @@
CURPATH="$(dirname "$0")"
if [ $# != 4 ] && [ $# != 5 ]
if [ $# != 4 ] && [ $# != 6 ]
then
echo "Usage: bash run_distribute_train.sh [RANK_TABLE_FILE] [PYTHON_PATH] [CONFIG_PATH] [DATASET_PATH] [CKPT_TYPE](optional) [CKPT_PATH](optional)"
exit 1
......@@ -41,10 +41,6 @@ then
exit 1
fi
if [ $# == 5 ]
then
PATH3=$(get_real_path $5)
fi
if [ ! -f $PATH1 ]
then
......@@ -58,36 +54,20 @@ then
exit 1
fi
if [ $# == 5 ] && [ ! -f $PATH3 ]
then
echo "error: FP32_CKPT=$PATH3 is not a file"
exit 1
fi
if [ $# == 5 ]; then
CKPT_TYPE=$4
CKPT_FILE=$(get_real_path $5)
if [ $# == 6 ]; then
CKPT_TYPE=$5
CKPT_FILE=$(get_real_path $6)
if [ "x$CKPT_TYPE" != "xFP32" ] && [ "x$CKPT_TYPE" != "xPRETRAINED" ]; then
echo "error: CKPT_TYPE=$CKPT_TYPE is not valid, should be FP32 or PRETRAINED"
exit 1
fi
if [ ! -f $CKPT_FILE ]; then
echo "error: CKPT_FILE=$CKPT_FILE is not a file"
echo "error: CKPT_PATH=$CKPT_FILE is not a file"
exit 1
fi
fi
if [ "x${RUN_EVAL}" == "xTrue" ] && [ ! -d $EVAL_DATASET_PATH ]
then
echo "error: EVAL_DATASET_PATH=$EVAL_DATASET_PATH is not a directory"
exit 1
fi
if [ "x${RUN_EVAL}" == "xTrue" ]
then
bootup_cache_server
fi
ulimit -u unlimited
export DEVICE_NUM=8
export RANK_SIZE=8
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment