aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorEdouard Leurent <eleurent@gmail.com>2022-10-08 16:49:43 +0100
committerAUTOMATIC1111 <16777216c@gmail.com>2022-10-08 22:35:04 +0300
commit610a7f4e1480c0ffeedb2a07dc27ae86bf03c3a8 (patch)
tree5bdc68d8796dba91d33cad3b613694c0300c902b /modules
parent3b2141c5fb6a3c2b8ab4b1e759a97ead77260129 (diff)
Break after finding the local directory of stable diffusion
Otherwise, we may override it with one of the next two path (. or ..) if it is present there, and then the local paths of other modules (taming transformers, codeformers, etc.) wont be found in sd_path/../. Fix https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/1085
Diffstat (limited to 'modules')
-rw-r--r--modules/paths.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/paths.py b/modules/paths.py
index 606f7d66..0519caa0 100644
--- a/modules/paths.py
+++ b/modules/paths.py
@@ -12,6 +12,7 @@ possible_sd_paths = [os.path.join(script_path, 'repositories/stable-diffusion'),
for possible_sd_path in possible_sd_paths:
if os.path.exists(os.path.join(possible_sd_path, 'ldm/models/diffusion/ddpm.py')):
sd_path = os.path.abspath(possible_sd_path)
+ break
assert sd_path is not None, "Couldn't find Stable Diffusion in any of: " + str(possible_sd_paths)