iandennismiller commited on
Commit
35da1d1
1 Parent(s): 756b4a3

expand home path

Browse files
Files changed (1) hide show
  1. bin/llama-hf-to-q6_k.sh +11 -10
bin/llama-hf-to-q6_k.sh CHANGED
@@ -5,19 +5,20 @@ if [ $# -ne 1 ]; then
5
  exit 1
6
  fi
7
 
8
- # if ~/.config/llama-hf-to-q6_k.conf does not exist, create it
9
- if [ ! -f ~/.config/llama-hf-to-q6_k.conf ]; then
10
- cat <<EOF > ~/.config/llama-hf-to-q6_k.conf
11
- MODELS_ROOT=~/.ai/models/llama/
12
- HF_DOWNLOADER=~/.ai/bin/hfdownloader
13
- STORAGE_PATH=~/scratch/hfdownloader
14
- PYTHON3_EXEC=~/.virtualenvs/llama.cpp/bin/python3
15
- QUANTIZE_EXEC=~/Work/llama.cpp/build/bin/quantize
16
- CONVERT_PY=~/Work/llama.cpp/convert.py
 
17
  EOF
18
  fi
19
 
20
- source ~/.config/llama-hf-to-q6_k.conf
21
 
22
  HF_NAME=$1
23
  ACCOUNT_NAME=$(echo "$HF_NAME" | cut -d '/' -f 1)
 
5
  exit 1
6
  fi
7
 
8
+ # if $HOME/.config/llama-hf-to-q6_k.conf does not exist, create it
9
+ if [ ! -f $HOME/.config/llama/llama-hf-to-q6_k.conf ]; then
10
+ mkdir -p $HOME/.config/llama
11
+ cat <<EOF > $HOME/.config/llama/llama-hf-to-q6_k.conf
12
+ MODELS_ROOT=$HOME/.ai/models/llama/
13
+ HF_DOWNLOADER=$HOME/.ai/bin/hfdownloader
14
+ STORAGE_PATH=$HOME/scratch/hfdownloader
15
+ PYTHON3_EXEC=$HOME/.virtualenvs/llama.cpp/bin/python3
16
+ QUANTIZE_EXEC=$HOME/Work/llama.cpp/build/bin/quantize
17
+ CONVERT_PY=$HOME/Work/llama.cpp/convert.py
18
  EOF
19
  fi
20
 
21
+ source $HOME/.config/llama-hf-to-q6_k.conf
22
 
23
  HF_NAME=$1
24
  ACCOUNT_NAME=$(echo "$HF_NAME" | cut -d '/' -f 1)