mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
Fixed startup issues with the web UI. (#2876)
This commit is contained in:
parent
21f79e5919
commit
c3ff9e6be8
@ -26,7 +26,7 @@ from ..args import APP_ID, APP_VERSION, Args, calculate_init_img_hash
|
|||||||
from ..generator import infill_methods
|
from ..generator import infill_methods
|
||||||
from ..globals import Globals, global_converted_ckpts_dir, global_models_dir
|
from ..globals import Globals, global_converted_ckpts_dir, global_models_dir
|
||||||
from ..image_util import PngWriter, retrieve_metadata
|
from ..image_util import PngWriter, retrieve_metadata
|
||||||
from ..model_management import merge_diffusion_models
|
from ...frontend.merge.merge_diffusers import merge_diffusion_models
|
||||||
from ..prompting import (
|
from ..prompting import (
|
||||||
get_prompt_structure,
|
get_prompt_structure,
|
||||||
get_tokenizer,
|
get_tokenizer,
|
||||||
|
@ -1294,13 +1294,15 @@ def run_patches():
|
|||||||
# distro after original root directory configuration
|
# distro after original root directory configuration
|
||||||
import invokeai.configs as conf
|
import invokeai.configs as conf
|
||||||
from shutil import copyfile
|
from shutil import copyfile
|
||||||
|
|
||||||
root_configs = Path(global_config_dir(), 'stable-diffusion')
|
root_configs = Path(global_config_dir(), 'stable-diffusion')
|
||||||
repo_configs = Path(conf.__path__[0], 'stable-diffusion')
|
repo_configs = Path(conf.__path__[0], 'stable-diffusion')
|
||||||
|
if not root_configs.exists():
|
||||||
|
os.makedirs(root_configs, exist_ok=True)
|
||||||
for src in repo_configs.iterdir():
|
for src in repo_configs.iterdir():
|
||||||
dest = root_configs / src.name
|
dest = root_configs / src.name
|
||||||
if not dest.exists():
|
if not dest.exists():
|
||||||
copyfile(src,dest)
|
copyfile(src, dest)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
|
Loading…
Reference in New Issue
Block a user