Add files via upload

Former-commit-id: 6f9fee815e
This commit is contained in:
Cyberes 2022-09-16 13:07:57 -06:00 committed by GitHub
parent aacdf18a6b
commit e2652d26cd
1 changed files with 10 additions and 59 deletions

View File

@ -132,21 +132,18 @@
"else:\n",
" print('GFPGANv1.3.pth already downloaded')\n",
" \n",
"!mkdir -p $model_storage_dir\n",
"\n",
"# Get some storage back\n",
"!pip cache purge\n",
"!sudo apt-get clean"
"!mkdir -p $model_storage_dir"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "F0EINk5M0s-w",
"jp-MarkdownHeadingCollapsed": true,
"tags": []
},
"source": [
"### Download the model"
"### Download the Model"
]
},
{
@ -174,7 +171,6 @@
{
"cell_type": "markdown",
"metadata": {
"jp-MarkdownHeadingCollapsed": true,
"tags": []
},
"source": [
@ -198,7 +194,7 @@
"!apt update\n",
"!apt install -y aria2\n",
"%cd $model_storage_dir\n",
"!aria2c --seed-time=0 --max-overall-upload-limit=1K \"magnet:?xt=urn:btih:3A4A612D75ED088EA542ACAC52F9F45987488D1C&tr=udp://tracker.opentrackr.org:1337\""
"!aria2c --seed-time=0 --max-overall-upload-limit=1K \"magnet:?xt=urn:btih:3A4A612D75ED088EA542ACAC52F9F45987488D1C&tr=udp://tracker.opentrackr.org:1337/announce\""
]
},
{
@ -234,69 +230,18 @@
{
"cell_type": "markdown",
"metadata": {
"jp-MarkdownHeadingCollapsed": true,
"tags": []
},
"source": [
"#### Waifu Diffusion"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"**Torrent**"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"!apt update\n",
"!apt install -y aria2\n",
"%cd $model_storage_dir\n",
"!aria2c --seed-time=0 --max-overall-upload-limit=1K \"magnet:?xt=urn:btih:F45CECF4E9DE86DA83A78DD2CCCD7F27D5557A52&tr=udp://nyquist.localghost.org:6969\""
]
},
{
"cell_type": "markdown",
"metadata": {
"tags": []
},
"source": [
"**Web Download**\n",
"\n",
"Very slow"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"%store -r model_storage_dir\n",
"!wget https://thisanimedoesnotexist.ai/downloads/wd-v1-2-full-ema.ckpt -O $model_storage_dir/wd-v1-2-full-ema.ckpt"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"**Half-Size Model**\n",
"\n",
"If you're on free tier try this first, it's 3.5GB."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"%store -r model_storage_dir\n",
"!apt update\n",
"!apt install -y aria2\n",
"%cd $model_storage_dir\n",
@ -408,8 +353,14 @@
"outputs": [],
"source": [
"%store -r model_storage_dir\n",
"\n",
"# Get some storage back\n",
"!pip cache purge\n",
"!sudo apt-get clean\n",
"!rm $model_storage_dir/*.aria2\n",
"!apt autoremove --purge -y aria2\n",
"\n",
"# Restart the kernel\n",
"import os\n",
"os.kill(os.getpid(), 9)"
]