Skip to content

Commit

Permalink
small fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ddPn08 committed Dec 19, 2022
1 parent a83f5cf commit 5b723b8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions automatic1111.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@
"cell_type": "code",
"execution_count": null,
"metadata": {
"cellView": "form",
"id": "Mls4_48XOrTd"
},
"outputs": [],
Expand Down Expand Up @@ -145,6 +144,7 @@
"os.makedirs(models_path, exist_ok=True)\n",
"os.makedirs(output_path, exist_ok=True)\n",
"os.makedirs(config_path, exist_ok=True)\n",
"os.makedirs(f\"{models_path}/Stable-diffusion\", exist_ok=True)\n",
"\n",
"for dir in os.listdir(models_path):\n",
" ! rm -Rf stable-diffusion-webui/models/{dir} && ln -s {models_path}/{dir} stable-diffusion-webui/models/{dir}\n",
Expand All @@ -158,7 +158,7 @@
" model_filename = model_url.split(\"/\")[-1]\n",
" if mount_google_drive and not mount_success:\n",
" print(f\"Downloading model to {models_path} due to gdrive mount error\")\n",
" elif not model_filename or not os.path.exists(f\"{data_dir}/models/{model_filename}\"):\n",
" elif not os.path.exists(f\"{data_dir}/models/Stable-diffusion/{model_filename}\"):\n",
" os.makedirs(f\"{models_path}/Stable-diffusion\", exist_ok=True)\n",
" ! curl -LJ {model_url} -o {models_path}/Stable-diffusion/{model_filename} {'-H \"Authorization: Bearer ' + auth_token + '\"' if auth_token else \"\"}\n",
" else:\n",
Expand Down Expand Up @@ -282,6 +282,7 @@
"cell_type": "code",
"execution_count": null,
"metadata": {
"cellView": "form",
"id": "Ao2t5h5qG9HD"
},
"outputs": [],
Expand Down

0 comments on commit 5b723b8

Please sign in to comment.