From 7495dc0e91106e870eee44c2ff911ddfdcd7f8c2 Mon Sep 17 00:00:00 2001 From: Maciej-GBS <12584491+Maciej-GBS@users.noreply.github.com> Date: Sun, 14 Jun 2020 18:32:19 +0200 Subject: [PATCH] Fixed error in mk-model script --- mk-model.sh | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/mk-model.sh b/mk-model.sh index 65fbcf1..15768d7 100755 --- a/mk-model.sh +++ b/mk-model.sh @@ -4,15 +4,21 @@ cd $1 echo $(pwd) -NUM=`cut -d -f 1 < model/.coach_checkpoint` +if [ "$1" = "" ]; then + echo "USAGE: $0 " +else -mkdir -p output/agent + NUM=`cut -d '_' -f 1 < model/.coach_checkpoint` -cp "model/model_$NUM.pb" output/agent/model.pb -cp model/model_metadata.json output/ + mkdir -p output/agent -cd output -tar -czvf ../output.tar.gz * + cp "model/model_$NUM.pb" output/agent/model.pb + cp model/model_metadata.json output/ -echo "done" + cd output + tar -czvf ../output.tar.gz * + + echo "done" + +fi