diff --git a/modules/async_worker.py b/modules/async_worker.py index 8e4d6d95..594886d2 100644 --- a/modules/async_worker.py +++ b/modules/async_worker.py @@ -237,10 +237,12 @@ def worker(): steps = performance_selection.steps() + performance_loras = [] + if performance_selection == Performance.EXTREME_SPEED: print('Enter LCM mode.') progressbar(async_task, 1, 'Downloading LCM components ...') - loras += [(modules.config.downloading_sdxl_lcm_lora(), 1.0)] + performance_loras += [(modules.config.downloading_sdxl_lcm_lora(), 1.0)] if refiner_model_name != 'None': print(f'Refiner disabled in LCM mode.') @@ -259,7 +261,7 @@ def worker(): elif performance_selection == Performance.LIGHTNING: print('Enter Lightning mode.') progressbar(async_task, 1, 'Downloading Lightning components ...') - loras += [(modules.config.downloading_sdxl_lightning_lora(), 1.0)] + performance_loras += [(modules.config.downloading_sdxl_lightning_lora(), 1.0)] if refiner_model_name != 'None': print(f'Refiner disabled in Lightning mode.') @@ -278,7 +280,7 @@ def worker(): elif performance_selection == Performance.HYPER_SD: print('Enter Hyper-SD mode.') progressbar(async_task, 1, 'Downloading Hyper-SD components ...') - loras += [(modules.config.downloading_sdxl_hyper_sd_lora(), 0.8)] + performance_loras += [(modules.config.downloading_sdxl_hyper_sd_lora(), 0.8)] if refiner_model_name != 'None': print(f'Refiner disabled in Hyper-SD mode.') @@ -458,8 +460,8 @@ def worker(): progressbar(async_task, 2, 'Loading models ...') - loras = parse_lora_references_from_prompt(prompt, loras, modules.config.default_max_lora_number) - + loras, prompt = parse_lora_references_from_prompt(prompt, loras, modules.config.default_max_lora_number) + loras += performance_loras pipeline.refresh_everything(refiner_model_name=refiner_model_name, base_model_name=base_model_name, loras=loras, base_model_additional_loras=base_model_additional_loras, use_synthetic_refiner=use_synthetic_refiner, vae_name=vae_name)