removed c flag in wget
This commit is contained in:
parent
02595f9d21
commit
faae84ee1d
1 changed files with 30 additions and 30 deletions
58
colab.ipynb
58
colab.ipynb
|
@ -3,8 +3,8 @@
|
||||||
{
|
{
|
||||||
"cell_type": "markdown",
|
"cell_type": "markdown",
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"id": "view-in-github",
|
"colab_type": "text",
|
||||||
"colab_type": "text"
|
"id": "view-in-github"
|
||||||
},
|
},
|
||||||
"source": [
|
"source": [
|
||||||
"<a href=\"https://colab.research.google.com/github/LostRuins/koboldcpp/blob/concedo/colab.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
|
"<a href=\"https://colab.research.google.com/github/LostRuins/koboldcpp/blob/concedo/colab.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
|
||||||
|
@ -46,40 +46,40 @@
|
||||||
},
|
},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"#@title <b>v-- Enter your model below and then click this to start Koboldcpp</b>\n",
|
"#@title <b>v-- Enter your model below and then click this to start Koboldcpp</b>\r\n",
|
||||||
"\n",
|
"\r\n",
|
||||||
"Model = \"https://huggingface.co/KoboldAI/LLaMA2-13B-Tiefighter-GGUF/resolve/main/LLaMA2-13B-Tiefighter.Q4_K_M.gguf\" #@param [\"https://huggingface.co/KoboldAI/LLaMA2-13B-Tiefighter-GGUF/resolve/main/LLaMA2-13B-Tiefighter.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/MythoMax-L2-13B-GGUF/resolve/main/mythomax-l2-13b.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/ReMM-SLERP-L2-13B-GGUF/resolve/main/remm-slerp-l2-13b.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/Xwin-LM-13B-v0.2-GGUF/resolve/main/xwin-lm-13b-v0.2.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/Stheno-L2-13B-GGUF/resolve/main/stheno-l2-13b.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/Mistral-7B-Instruct-v0.1-GGUF/resolve/main/mistral-7b-instruct-v0.1.Q4_K_S.gguf\"]{allow-input: true}\n",
|
"Model = \"https://huggingface.co/KoboldAI/LLaMA2-13B-Tiefighter-GGUF/resolve/main/LLaMA2-13B-Tiefighter.Q4_K_M.gguf\" #@param [\"https://huggingface.co/KoboldAI/LLaMA2-13B-Tiefighter-GGUF/resolve/main/LLaMA2-13B-Tiefighter.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/MythoMax-L2-13B-GGUF/resolve/main/mythomax-l2-13b.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/ReMM-SLERP-L2-13B-GGUF/resolve/main/remm-slerp-l2-13b.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/Xwin-LM-13B-v0.2-GGUF/resolve/main/xwin-lm-13b-v0.2.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/Stheno-L2-13B-GGUF/resolve/main/stheno-l2-13b.Q4_K_M.gguf\",\"https://huggingface.co/TheBloke/Mistral-7B-Instruct-v0.1-GGUF/resolve/main/mistral-7b-instruct-v0.1.Q4_K_S.gguf\"]{allow-input: true}\r\n",
|
||||||
"Layers = 43 #@param [43]{allow-input: true}\n",
|
"Layers = 43 #@param [43]{allow-input: true}\r\n",
|
||||||
"ContextSize = 4096 #@param [4096] {allow-input: true}\n",
|
"ContextSize = 4096 #@param [4096] {allow-input: true}\r\n",
|
||||||
"\n",
|
"\r\n",
|
||||||
"import os\n",
|
"import os\r\n",
|
||||||
"if not os.path.isfile(\"/opt/bin/nvidia-smi\"):\n",
|
"if not os.path.isfile(\"/opt/bin/nvidia-smi\"):\r\n",
|
||||||
" raise RuntimeError(\"⚠️Colab did not give you a GPU due to usage limits, this can take a few hours before they let you back in. Check out https://lite.koboldai.net for a free alternative (that does not provide an API link but can load KoboldAI saves and chat cards) or subscribe to Colab Pro for immediate access.⚠️\")\n",
|
" raise RuntimeError(\"⚠️Colab did not give you a GPU due to usage limits, this can take a few hours before they let you back in. Check out https://lite.koboldai.net for a free alternative (that does not provide an API link but can load KoboldAI saves and chat cards) or subscribe to Colab Pro for immediate access.⚠️\")\r\n",
|
||||||
"\n",
|
"\r\n",
|
||||||
"%cd /content\n",
|
"%cd /content\r\n",
|
||||||
"!git clone https://github.com/LostRuins/koboldcpp\n",
|
"!git clone https://github.com/LostRuins/koboldcpp\r\n",
|
||||||
"%cd /content/koboldcpp\n",
|
"%cd /content/koboldcpp\r\n",
|
||||||
"kvers = !(cat koboldcpp.py | grep 'KcppVersion = ' | cut -d '\"' -f2)\n",
|
"kvers = !(cat koboldcpp.py | grep 'KcppVersion = ' | cut -d '\"' -f2)\r\n",
|
||||||
"kvers = kvers[0]\n",
|
"kvers = kvers[0]\r\n",
|
||||||
"!echo Finding prebuilt binary for {kvers}\n",
|
"!echo Finding prebuilt binary for {kvers}\r\n",
|
||||||
"!wget -O dlfile.tmp -c https://kcppcolab.concedo.workers.dev/?{kvers} && mv dlfile.tmp koboldcpp_cublas.so\n",
|
"!wget -O dlfile.tmp https://kcppcolab.concedo.workers.dev/?{kvers} && mv dlfile.tmp koboldcpp_cublas.so\r\n",
|
||||||
"!test -f koboldcpp_cublas.so && echo Prebuilt Binary Exists || echo Prebuilt Binary Does Not Exist\n",
|
"!test -f koboldcpp_cublas.so && echo Prebuilt Binary Exists || echo Prebuilt Binary Does Not Exist\r\n",
|
||||||
"!test -f koboldcpp_cublas.so && echo Build Skipped || make koboldcpp_cublas LLAMA_CUBLAS=1\n",
|
"!test -f koboldcpp_cublas.so && echo Build Skipped || make koboldcpp_cublas LLAMA_CUBLAS=1\r\n",
|
||||||
"!cp koboldcpp_cublas.so koboldcpp_cublas.dat\n",
|
"!cp koboldcpp_cublas.so koboldcpp_cublas.dat\r\n",
|
||||||
"!apt install aria2 -y\n",
|
"!apt install aria2 -y\r\n",
|
||||||
"!aria2c -x 10 -o model.ggml --allow-overwrite=true --file-allocation=none $Model\n",
|
"!aria2c -x 10 -o model.ggml --allow-overwrite=true --file-allocation=none $Model\r\n",
|
||||||
"!python koboldcpp.py model.ggml --usecublas 0 mmq --multiuser --gpulayers $Layers --contextsize $ContextSize --hordeconfig concedo 1 1 --remotetunnel\n"
|
"!python koboldcpp.py model.ggml --usecublas 0 mmq --multiuser --gpulayers $Layers --contextsize $ContextSize --hordeconfig concedo 1 1 --remotetunnel\r\n"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"accelerator": "GPU",
|
"accelerator": "GPU",
|
||||||
"colab": {
|
"colab": {
|
||||||
"gpuType": "T4",
|
|
||||||
"private_outputs": true,
|
|
||||||
"provenance": [],
|
|
||||||
"cell_execution_strategy": "setup",
|
"cell_execution_strategy": "setup",
|
||||||
"include_colab_link": true
|
"gpuType": "T4",
|
||||||
|
"include_colab_link": true,
|
||||||
|
"private_outputs": true,
|
||||||
|
"provenance": []
|
||||||
},
|
},
|
||||||
"kernelspec": {
|
"kernelspec": {
|
||||||
"display_name": "Python 3",
|
"display_name": "Python 3",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue