From 2b9a3d32c9402ef86f56a71562147c250db04f3f Mon Sep 17 00:00:00 2001 From: Richard Palethorpe Date: Fri, 12 Sep 2025 11:28:20 +0100 Subject: [PATCH] =?UTF-8?q?chore:=20=E2=AC=86=EF=B8=8F=20Update=20leejet/s?= =?UTF-8?q?table-diffusion.cpp=20to=20fce6afcc6a3250a8e17923608922d2a99b33?= =?UTF-8?q?9b47=20(#6256)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * :arrow_up: Update leejet/stable-diffusion.cpp Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * fix(stablediffusion-ggml): Add SMOOTHSTEP scheduler and assert sampler and scheduler counts Signed-off-by: Richard Palethorpe --------- Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Signed-off-by: Richard Palethorpe Co-authored-by: mudler <2420543+mudler@users.noreply.github.com> --- backend/go/stablediffusion-ggml/Makefile | 2 +- backend/go/stablediffusion-ggml/gosd.cpp | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/backend/go/stablediffusion-ggml/Makefile b/backend/go/stablediffusion-ggml/Makefile index 51f087141..9aa74c27f 100644 --- a/backend/go/stablediffusion-ggml/Makefile +++ b/backend/go/stablediffusion-ggml/Makefile @@ -8,7 +8,7 @@ JOBS?=$(shell nproc --ignore=1) # stablediffusion.cpp (ggml) STABLEDIFFUSION_GGML_REPO?=https://github.com/leejet/stable-diffusion.cpp -STABLEDIFFUSION_GGML_VERSION?=b0179181069254389ccad604e44f17a2c25b4094 +STABLEDIFFUSION_GGML_VERSION?=fce6afcc6a3250a8e17923608922d2a99b339b47 CMAKE_ARGS+=-DGGML_MAX_NAME=128 diff --git a/backend/go/stablediffusion-ggml/gosd.cpp b/backend/go/stablediffusion-ggml/gosd.cpp index b2026fdb3..4a2e01da4 100644 --- a/backend/go/stablediffusion-ggml/gosd.cpp +++ b/backend/go/stablediffusion-ggml/gosd.cpp @@ -43,6 +43,8 @@ const char* sample_method_str[] = { "tcd", }; +static_assert(std::size(sample_method_str) == SAMPLE_METHOD_COUNT, "sample method mismatch"); + // Names of the sigma schedule overrides, same order as sample_schedule in stable-diffusion.h const char* schedulers[] = { "default", @@ -51,8 +53,11 @@ const char* schedulers[] = { "exponential", "ays", "gits", + "smoothstep", }; +static_assert(std::size(schedulers) == SCHEDULE_COUNT, "schedulers mismatch"); + sd_ctx_t* sd_c; // Moved from the context (load time) to generation time params scheduler_t scheduler = scheduler_t::DEFAULT;