forked from mindspore-Ecosystem/mindspore
mode zoo wide&deep bash modify
This commit is contained in:
parent
10fd781b15
commit
49d22b31d2
|
@ -16,7 +16,8 @@
|
|||
|
||||
# bash run_multinpu_train.sh
|
||||
execute_path=$(pwd)
|
||||
|
||||
script_self=$(readlink -f "$0")
|
||||
self_path=$(dirname "${script_self}")
|
||||
export RANK_SIZE=$1
|
||||
export EPOCH_SIZE=$2
|
||||
export DATASET=$3
|
||||
|
@ -30,5 +31,5 @@ do
|
|||
cd ${execute_path}/device_$i/ || exit
|
||||
export RANK_ID=$i
|
||||
export DEVICE_ID=$i
|
||||
pytest -s ${execute_path}/train_and_test_multinpu.py --data_path=$DATASET --epochs=$EPOCH_SIZE >train_deep$i.log 2>&1 &
|
||||
python -s ${self_path}/../train_and_test_multinpu.py --data_path=$DATASET --epochs=$EPOCH_SIZE >train_deep$i.log 2>&1 &
|
||||
done
|
||||
|
|
|
@ -66,12 +66,11 @@ class ModelBuilder():
|
|||
return get_WideDeep_net(config)
|
||||
|
||||
|
||||
def test_train_eval():
|
||||
def test_train_eval(config):
|
||||
"""
|
||||
test_train_eval
|
||||
"""
|
||||
np.random.seed(1000)
|
||||
config = WideDeepConfig()
|
||||
data_path = config.data_path
|
||||
batch_size = config.batch_size
|
||||
epochs = config.epochs
|
||||
|
@ -104,4 +103,6 @@ def test_train_eval():
|
|||
|
||||
|
||||
if __name__ == "__main__":
|
||||
test_train_eval()
|
||||
wide_deep_config = WideDeepConfig()
|
||||
wide_deep_config.argparse_init()
|
||||
test_train_eval(wide_deep_config)
|
||||
|
|
Loading…
Reference in New Issue