From 979970a32036fa59cbfd8631d034a5c5030be183 Mon Sep 17 00:00:00 2001 From: Jack Woo Date: Tue, 2 Jan 2024 23:44:27 -0800 Subject: [PATCH 1/2] Fixed #370 - Seq command compatability issue --- download.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/download.sh b/download.sh index 9ba1b533c..b109b375e 100755 --- a/download.sh +++ b/download.sh @@ -11,7 +11,7 @@ read -p "Enter the list of models to download without spaces (7B,13B,70B,7B-chat TARGET_FOLDER="." # where all files should end up mkdir -p ${TARGET_FOLDER} -if [[ $MODEL_SIZE == "" ]]; then +if [[ "$MODEL_SIZE" == "" ]]; then MODEL_SIZE="7B,13B,70B,7B-chat,13B-chat,70B-chat" fi @@ -54,9 +54,10 @@ do echo "Downloading ${MODEL_PATH}" mkdir -p ${TARGET_FOLDER}"/${MODEL_PATH}" - for s in $(seq -f "0%g" 0 ${SHARD}) + for s in $(seq 0 ${SHARD}) do - wget --continue ${PRESIGNED_URL/'*'/"${MODEL_PATH}/consolidated.${s}.pth"} -O ${TARGET_FOLDER}"/${MODEL_PATH}/consolidated.${s}.pth" + sf=$(printf "%02d" $s) + wget --continue ${PRESIGNED_URL/'*'/"${MODEL_PATH}/consolidated.${sf}.pth"} -O ${TARGET_FOLDER}"/${MODEL_PATH}/consolidated.${sf}.pth" done wget --continue ${PRESIGNED_URL/'*'/"${MODEL_PATH}/params.json"} -O ${TARGET_FOLDER}"/${MODEL_PATH}/params.json" From 826f4ca93c6d5a08045ad0b636efae445f20c754 Mon Sep 17 00:00:00 2001 From: Jack Woo Date: Tue, 2 Jan 2024 23:49:39 -0800 Subject: [PATCH 2/2] Formatting --- download.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/download.sh b/download.sh index b109b375e..282c4d472 100755 --- a/download.sh +++ b/download.sh @@ -56,7 +56,7 @@ do for s in $(seq 0 ${SHARD}) do - sf=$(printf "%02d" $s) + sf=$(printf "%02d" $s) wget --continue ${PRESIGNED_URL/'*'/"${MODEL_PATH}/consolidated.${sf}.pth"} -O ${TARGET_FOLDER}"/${MODEL_PATH}/consolidated.${sf}.pth" done