More settings
This commit is contained in:
parent
ddd2563f54
commit
9c04f9fc9c
|
@ -81,6 +81,9 @@
|
|||
"activate_xformers = False # Enables the xformers optimizations using pre-built wheels.\n",
|
||||
" # Setting to True will automatically set up your environment/machine for xformers. \n",
|
||||
"\n",
|
||||
"xformers_leave_cuda = False # When installing xformers, skip installing cuda 11.3\n",
|
||||
" # Useful if your're re-running the install block and already installed cuda 11.3\n",
|
||||
"\n",
|
||||
"link_novelai_anime_vae = False # Enables the linking of animevae.pt to each of the NovelAI models.\n",
|
||||
" # Set to True if you've downloaded both the NovelAI models and hypernetworks.\n",
|
||||
"\n",
|
||||
|
@ -98,10 +101,10 @@
|
|||
"\n",
|
||||
"gradio_port = False # Launch Gradio on a specific port. Set to False to let Gradio choose a port.\n",
|
||||
" # This disables online Gradio app mode and you will only be able to access it on your local network.\n",
|
||||
"\n",
|
||||
" \n",
|
||||
"# ===============================================================\n",
|
||||
"# Save variables to Jupiter's temp storage so we can access it even if the kernel restarts.\n",
|
||||
"%store free_tier model_storage_dir repo_storage_dir activate_xformers link_novelai_anime_vae download_scripts activate_deepdanbooru activate_medvram disable_pickle_check gradio_port"
|
||||
"%store free_tier model_storage_dir repo_storage_dir activate_xformers link_novelai_anime_vae download_scripts activate_deepdanbooru activate_medvram disable_pickle_check gradio_port xformers_leave_cuda"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
@ -181,7 +184,7 @@
|
|||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"%store -r free_tier model_storage_dir repo_storage_dir activate_xformers download_scripts activate_deepdanbooru\n",
|
||||
"%store -r free_tier model_storage_dir repo_storage_dir activate_xformers download_scripts activate_deepdanbooru xformers_leave_cuda\n",
|
||||
"%cd \"{repo_storage_dir}/stable-diffusion-webui\"\n",
|
||||
"import os\n",
|
||||
"\n",
|
||||
|
@ -258,6 +261,7 @@
|
|||
" !git clone https://github.com/adieyal/sd-dynamic-prompting/ extensions/dynamic-prompts\n",
|
||||
"\n",
|
||||
"if activate_xformers:\n",
|
||||
" print('Installing xformers...')\n",
|
||||
" import subprocess\n",
|
||||
" def download_release(url):\n",
|
||||
" binary = 'xformers-0.0.14.dev0-cp39-cp39-linux_x86_64.whl' # have to save the binary as a specific name that pip likes\n",
|
||||
|
@ -265,6 +269,8 @@
|
|||
" !wget \"{url}\" -O \"{tmp_dir}/{binary}\"\n",
|
||||
" return os.path.join(tmp_dir, binary)\n",
|
||||
"\n",
|
||||
" if not xformers_leave_cuda:\n",
|
||||
" print('Skipping installing cuda')\n",
|
||||
" # Completly remove cuda from your system\n",
|
||||
" # The container comes with cuda 11.2 installed which is incompatable with pytorch\n",
|
||||
" # We MUST install cuda 11.3\n",
|
||||
|
@ -278,8 +284,7 @@
|
|||
" # Set up pip packages\n",
|
||||
" !pip uninstall -y torch torchvision torchaudio # Remove existing pytorch install.\n",
|
||||
" !pip install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu113 # Install pytorch for cuda 11.3\n",
|
||||
" from subprocess import getoutput\n",
|
||||
" s = getoutput('nvidia-smi')\n",
|
||||
" s = subprocess.getoutput('nvidia-smi')\n",
|
||||
" if 'A4000' in s:\n",
|
||||
" xformers_whl = download_release('https://github.com/Cyberes/xformers-compiled/releases/download/A4000-Oct-28-2022/a4000-xformers-0.0.14.dev0-cp39-cp39-linux_x86_64.whl')\n",
|
||||
" elif 'A5000' in s:\n",
|
||||
|
@ -312,14 +317,13 @@
|
|||
"!ln -s \"{repo_storage_dir}/stable-diffusion-webui/outputs\" /notebooks/\n",
|
||||
"!ln -s \"{repo_storage_dir}/stable-diffusion-webui/log\" \"{repo_storage_dir}/stable-diffusion-webui/outputs\"\n",
|
||||
"\n",
|
||||
"!echo -e \"\\n===================================\\nDone! If you're seeing this the process exited successfully.\\n\""
|
||||
"!echo -e \"\\n===================================\\nDone! If you're seeing this the process has exited successfully.\\n\""
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {
|
||||
"id": "F0EINk5M0s-w",
|
||||
"jp-MarkdownHeadingCollapsed": true,
|
||||
"tags": []
|
||||
},
|
||||
"source": [
|
||||
|
@ -336,8 +340,6 @@
|
|||
"\n",
|
||||
"**There are additional models available here: https://cyberes.github.io/stable-diffusion-models**\n",
|
||||
"\n",
|
||||
"<br>\n",
|
||||
"\n",
|
||||
"Textual inversion: https://cyberes.github.io/stable-diffusion-textual-inversion-models\n",
|
||||
"\n",
|
||||
"DreamBooth: https://cyberes.github.io/stable-diffusion-dreambooth-library\n",
|
||||
|
@ -382,7 +384,7 @@
|
|||
"%store -r free_tier model_storage_dir repo_storage_dir\n",
|
||||
"!apt update\n",
|
||||
"!apt install -y aria2\n",
|
||||
"%cd $model_storage_dir\n",
|
||||
"%cd \"{model_storage_dir}\"\n",
|
||||
"!aria2c --seed-time=0 --max-overall-upload-limit=1K --bt-max-peers=120 --summary-interval=0 --file-allocation=none \"magnet:?xt=urn:btih:2daef5b5f63a16a9af9169a529b1a773fc452637&dn=v1-5-pruned-emaonly.ckpt&tr=udp%3a%2f%2ftracker.opentrackr.org%3a1337%2fannounce&tr=udp%3a%2f%2f9.rarbg.com%3a2810%2fannounce&tr=udp%3a%2f%2ftracker.openbittorrent.com%3a6969%2fannounce&tr=udp%3a%2f%2fopentracker.i2p.rocks%3a6969%2fannounce&tr=https%3a%2f%2fopentracker.i2p.rocks%3a443%2fannounce&tr=http%3a%2f%2ftracker.openbittorrent.com%3a80%2fannounce&tr=udp%3a%2f%2ftracker.torrent.eu.org%3a451%2fannounce&tr=udp%3a%2f%2fopen.stealth.si%3a80%2fannounce&tr=udp%3a%2f%2fvibe.sleepyinternetfun.xyz%3a1738%2fannounce&tr=udp%3a%2f%2ftracker2.dler.org%3a80%2fannounce&tr=udp%3a%2f%2ftracker1.bt.moack.co.kr%3a80%2fannounce&tr=udp%3a%2f%2ftracker.zemoj.com%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.tiny-vps.com%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.theoks.net%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.publictracker.xyz%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.monitorit4.me%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.moeking.me%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.lelux.fi%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.dler.org%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.army%3a6969%2fannounce\""
|
||||
]
|
||||
},
|
||||
|
@ -402,7 +404,7 @@
|
|||
"%store -r free_tier model_storage_dir repo_storage_dir\n",
|
||||
"!apt update\n",
|
||||
"!apt install -y aria2\n",
|
||||
"%cd $model_storage_dir\n",
|
||||
"%cd \"{model_storage_dir}\"\n",
|
||||
"!aria2c --seed-time=0 --max-overall-upload-limit=1K --bt-max-peers=120 --summary-interval=0 --file-allocation=none \"magnet:?xt=urn:btih:b523a9e71ae02e27b28007eca190f41999c2add1&dn=sd-v1-5-inpainting.ckpt&tr=udp%3a%2f%2ftracker.opentrackr.org%3a1337%2fannounce&tr=udp%3a%2f%2f9.rarbg.com%3a2810%2fannounce&tr=udp%3a%2f%2ftracker.openbittorrent.com%3a6969%2fannounce&tr=http%3a%2f%2ftracker.openbittorrent.com%3a80%2fannounce&tr=udp%3a%2f%2fopentracker.i2p.rocks%3a6969%2fannounce&tr=https%3a%2f%2fopentracker.i2p.rocks%3a443%2fannounce&tr=udp%3a%2f%2ftracker.torrent.eu.org%3a451%2fannounce&tr=udp%3a%2f%2fopen.stealth.si%3a80%2fannounce&tr=udp%3a%2f%2fvibe.sleepyinternetfun.xyz%3a1738%2fannounce&tr=udp%3a%2f%2ftracker2.dler.org%3a80%2fannounce&tr=udp%3a%2f%2ftracker1.bt.moack.co.kr%3a80%2fannounce&tr=udp%3a%2f%2ftracker.zemoj.com%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.tiny-vps.com%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.theoks.net%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.swateam.org.uk%3a2710%2fannounce&tr=udp%3a%2f%2ftracker.publictracker.xyz%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.pomf.se%3a80%2fannounce&tr=udp%3a%2f%2ftracker.monitorit4.me%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.moeking.me%3a6969%2fannounce&tr=udp%3a%2f%2ftracker.lelux.fi%3a6969%2fannounce\""
|
||||
]
|
||||
},
|
||||
|
@ -424,7 +426,7 @@
|
|||
"%store -r free_tier model_storage_dir repo_storage_dir\n",
|
||||
"!apt update\n",
|
||||
"!apt install -y aria2\n",
|
||||
"%cd $model_storage_dir\n",
|
||||
"%cd \"{model_storage_dir}\"\n",
|
||||
"!aria2c --seed-time=0 --max-overall-upload-limit=1K --bt-max-peers=120 --summary-interval=0 --file-allocation=none \"magnet:?xt=urn:btih:3A4A612D75ED088EA542ACAC52F9F45987488D1C&tr=udp://tracker.opentrackr.org:1337/announce\""
|
||||
]
|
||||
},
|
||||
|
@ -800,7 +802,9 @@
|
|||
"#### Troubleshooting\n",
|
||||
"- If you have any issues, try restarting the kernel.\n",
|
||||
"- `EOFError: Ran out of input` probably means you ran out of storage space and the model `.ckpt` file wasn't downloaded completely. Try cleaning up your files. There are some helpful scripts in the Tools section below.\n",
|
||||
"- `The file may be malicious, so the program is not going to read it` means the program encountered unexpected data in the model file (the technical term is \"pickle\"). Merging models can cause this. You can disable this feature by setting `disable_pickle_check` to True in the settings block. A pickle file can contain arbitrary code so be careful, you don't want to get pickled!"
|
||||
"- `The file may be malicious, so the program is not going to read it` means the program encountered unexpected data in the model file (the technical term is \"pickle\"). Merging models can cause this. You can disable this feature by setting `disable_pickle_check` to True in the settings block.\n",
|
||||
"- Try updating your notebook using the block in the Tools section below.\n",
|
||||
"- If you're still having issues, delete `stable-diffusion-webui` and reinstall."
|
||||
]
|
||||
},
|
||||
{
|
||||
|
@ -1059,7 +1063,7 @@
|
|||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.9.13"
|
||||
"version": "3.9.15"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
|
|
Loading…
Reference in New Issue