Skip to content

Commit c3494a0

Browse files
richiejpmudler
andauthored
chore: ⬆️ Update leejet/stable-diffusion.cpp to bda7fab9f208dff4b67179a68f694b6ddec13326 (#7639)
* ⬆️ Update leejet/stable-diffusion.cpp Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * fix(stablediffusion-ggml): Don't set removed lora model dir Signed-off-by: Richard Palethorpe <io@richiejp.com> --------- Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Signed-off-by: Richard Palethorpe <io@richiejp.com> Co-authored-by: mudler <2420543+mudler@users.noreply.github.com>
1 parent 716dba9 commit c3494a0

2 files changed

Lines changed: 6 additions & 10 deletions

File tree

backend/go/stablediffusion-ggml/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ JOBS?=$(shell nproc --ignore=1)
88

99
# stablediffusion.cpp (ggml)
1010
STABLEDIFFUSION_GGML_REPO?=https://github.com/leejet/stable-diffusion.cpp
11-
STABLEDIFFUSION_GGML_VERSION?=200cb6f2ca07e40fa83b610a4e595f4da06ec709
11+
STABLEDIFFUSION_GGML_VERSION?=bda7fab9f208dff4b67179a68f694b6ddec13326
1212

1313
CMAKE_ARGS+=-DGGML_MAX_NAME=128
1414

backend/go/stablediffusion-ggml/gosd.cpp

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -688,7 +688,6 @@ int load_model(const char *model, char *model_path, char* options[], int threads
688688
ctx_params.vae_path = vae_path;
689689
ctx_params.taesd_path = taesd_path;
690690
ctx_params.control_net_path = control_net_path;
691-
ctx_params.lora_model_dir = lora_dir;
692691
if (lora_dir && strlen(lora_dir) > 0) {
693692
lora_dir_path = std::string(lora_dir);
694693
fprintf(stderr, "LoRA model directory set to: %s\n", lora_dir);
@@ -801,21 +800,18 @@ void sd_img_gen_params_set_prompts(sd_img_gen_params_t *params, const char *prom
801800
// Clear previous LoRA data
802801
lora_vec.clear();
803802
lora_strings.clear();
804-
803+
805804
// Parse LoRAs from prompt
806805
std::string prompt_str = prompt ? prompt : "";
807806
std::string negative_prompt_str = negative_prompt ? negative_prompt : "";
808-
807+
809808
// Get lora_dir from ctx_params if available, otherwise use stored path
810-
const char* lora_dir_to_use = ctx_params.lora_model_dir;
811-
if (!lora_dir_to_use || strlen(lora_dir_to_use) == 0) {
812-
lora_dir_to_use = lora_dir_path.empty() ? nullptr : lora_dir_path.c_str();
813-
}
814-
809+
const char* lora_dir_to_use = lora_dir_path.empty() ? nullptr : lora_dir_path.c_str();
810+
815811
auto [loras, cleaned_prompt] = parse_loras_from_prompt(prompt_str, lora_dir_to_use);
816812
lora_vec = loras;
817813
cleaned_prompt_storage = cleaned_prompt;
818-
814+
819815
// Also check negative prompt for LoRAs (though this is less common)
820816
auto [neg_loras, cleaned_negative] = parse_loras_from_prompt(negative_prompt_str, lora_dir_to_use);
821817
// Merge negative prompt LoRAs (though typically not used)

0 commit comments

Comments
 (0)