Advertisement
Guest User

Untitled

a guest
Apr 2nd, 2024
208
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.97 KB | Source Code | 0 0
  1. LLAMA_BIN=./llama.cpp/main
  2. MODEL_DIR=./llama.cpp/models
  3. PROMPT_LLAMA=$(cat <<EOF
  4. <s>[INST] Repeat this text: "The different accidents of life are not so changeable as the feelings of human nature. I had worked hard for nearly two years, for the sole purpose of infusing life into an inanimate body. For this I had deprived myself of rest and health. I had desired it with an ardour that far exceeded moderation; but now that I had finished, the beauty of the dream vanished, and breathless horror and disgust filled my heart." [/INST]
  5. EOF
  6. )
  7.  
  8. for MODEL in llama-2-7b-chat.Q4_K_M.gguf llama-2-7b-chat.Q8_0.gguf llama-2-13b-chat.Q4_K_M.gguf llama-2-13b-chat.Q8_0.gguf llama-2-70b-chat.Q4_K_M.gguf llama-2-70b-chat.Q8_0.gguf
  9. do
  10.     echo 3 > /proc/sys/vm/drop_caches
  11.     for NTHREADS in 8 12 16 24 32 48 64
  12.     do
  13.         echo "Testing model $MODEL with $NTHREADS threads"
  14.         $LLAMA_BIN --numa distribute -s 42 -t $NTHREADS -m $MODEL_DIR/$MODEL -b 1024 -c 1024 --temp 0.01 -p "$PROMPT_LLAMA"
  15.     done
  16. done
  17.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement