Skip to content

Commit 0469508

Browse files
committed
refactor: t5 use cpu if conditioner type != model type
Signed-off-by: thxCode <thxcode0824@gmail.com>
1 parent 8e11b5a commit 0469508

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

stable-diffusion.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ class StableDiffusionGGML {
343343
if (version == VERSION_SD3_MEDIUM || version == VERSION_SD3_5_MEDIUM || version == VERSION_SD3_5_LARGE || version == VERSION_FLUX_DEV || version == VERSION_FLUX_SCHNELL) {
344344
use_t5xxl = true;
345345
}
346-
if (!ggml_backend_is_cpu(backend) && use_t5xxl && conditioner_wtype < GGML_TYPE_F16) {
346+
if (!ggml_backend_is_cpu(backend) && use_t5xxl && conditioner_wtype != diffusion_model_wtype) {
347347
clip_on_cpu = true;
348348
LOG_INFO("set clip_on_cpu to true");
349349
}

0 commit comments

Comments
 (0)