tunable force lora loading method

This commit is contained in:
Vladimir Mandic
2024-05-06 20:20:59 -04:00
parent 79b018c1e8
commit a697366951
3 changed files with 5 additions and 1 deletions
+1
View File
@@ -133,6 +133,7 @@ it is time to give credit to original [author](https://github.com/auTOMATIC1111)
- **Fixes**:
- Update requirements
- Prompt params parser
- Allowing forcing LoRA loading method for some or all models
- Image save without metadata
- API generate save metadata
- Face/InstantID faults
@@ -20,6 +20,8 @@ force_diffusers = [
]
def check_override(shorthash):
if not shared.opts.lora_maybe_diffusers:
return False
if len(shorthash) < 4:
return False
force = any([x.startswith(shorthash) for x in force_diffusers])
+2 -1
View File
@@ -806,7 +806,8 @@ options_templates.update(options_section(('extra_networks', "Extra Networks"), {
"extra_networks_styles": OptionInfo(True, "Show built-in styles"),
"lora_preferred_name": OptionInfo("filename", "LoRA preferred name", gr.Radio, {"choices": ["filename", "alias"]}),
"lora_add_hashes_to_infotext": OptionInfo(True, "LoRA add hash info"),
"lora_force_diffusers": OptionInfo(False if not cmd_opts.use_openvino else True, "LoRA use alternative loading method"),
"lora_force_diffusers": OptionInfo(False if not cmd_opts.use_openvino else True, "LoRA force loading of all models using Diffusers"),
"lora_maybe_diffusers": OptionInfo(False, "LoRA force loading of specific models using Diffusers"),
"lora_fuse_diffusers": OptionInfo(False if not cmd_opts.use_openvino else True, "LoRA use merge when using alternative method"),
"lora_in_memory_limit": OptionInfo(1 if not cmd_opts.use_openvino else 0, "LoRA memory cache", gr.Slider, {"minimum": 0, "maximum": 24, "step": 1}),
"lora_functional": OptionInfo(False, "Use Kohya method for handling multiple LoRA", gr.Checkbox, { "visible": False }),