diff --git a/llama.sh b/llama.sh index 6308ce0..938988e 100755 --- a/llama.sh +++ b/llama.sh @@ -30,7 +30,11 @@ do mkdir -p ${TARGET_FOLDER}"/${i}" for s in $(seq -f "0%g" 0 ${N_SHARD_DICT[$i]}) do - wget ${PRESIGNED_URL/'*'/"${i}/consolidated.${s}.pth"} -O ${TARGET_FOLDER}"/${i}/consolidated.${s}.pth" + if ! which aria2c 2>&1 > /dev/null; then + wget ${PRESIGNED_URL/'*'/"${i}/consolidated.${s}.pth"} -O ${TARGET_FOLDER}"/${i}/consolidated.${s}.pth" + else + aria2c -c -s10 -x10 -k1M ${PRESIGNED_URL/'*'/"${i}/consolidated.${s}.pth"} -o ${TARGET_FOLDER}"/${i}/consolidated.${s}.pth" + fi done wget ${PRESIGNED_URL/'*'/"${i}/params.json"} -O ${TARGET_FOLDER}"/${i}/params.json" wget ${PRESIGNED_URL/'*'/"${i}/checklist.chk"} -O ${TARGET_FOLDER}"/${i}/checklist.chk"