feat: add fail mark for fail process
This commit is contained in:
parent
4d27d046a0
commit
87b6708a8b
|
@ -53,11 +53,16 @@ else
|
||||||
fi
|
fi
|
||||||
|
|
||||||
wait $train_pid
|
wait $train_pid
|
||||||
|
train_status=$?
|
||||||
echo "Train ended"
|
echo "Train ended"
|
||||||
|
|
||||||
sleep 60
|
sleep 60
|
||||||
kill $npu_status_pid
|
kill $npu_status_pid
|
||||||
echo "Npu status ended"
|
echo "Npu status ended"
|
||||||
|
|
||||||
|
if [ $train_status -ne 0 ]; then
|
||||||
|
output_dir="${output_dir}_fail"
|
||||||
|
fi
|
||||||
|
|
||||||
python3 -c "import moxing as mox; mox.file.copy_parallel('${output_dir}', 'obs://xty/results/${run_name}')"
|
python3 -c "import moxing as mox; mox.file.copy_parallel('${output_dir}', 'obs://xty/results/${run_name}')"
|
||||||
rm -r ${output_dir}
|
rm -r ${output_dir}
|
Loading…
Reference in New Issue