From 74c606384deb5f8e1f6e37f8bd38f85bfc41daf7 Mon Sep 17 00:00:00 2001 From: one-lithe-rune Date: Tue, 30 Jul 2024 13:41:38 +0100 Subject: [PATCH] Add ays, clip skip and vae, to image embedded params - If 'ays' is set as the scheduler include it in the 'Sampler' tag in the data embedded into the final image. This makes it the same as how Karras is handled - If a custom VAE path is set, include the vae name (without path and extension) in embedded image params under a `VAE:` tag. - If a custom Clip skip is set, include that Clip skip value in embedded image params under a `Clip skip:` tag. --- examples/cli/main.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/examples/cli/main.cpp b/examples/cli/main.cpp index 6675095b5..5a8cc5661 100644 --- a/examples/cli/main.cpp +++ b/examples/cli/main.cpp @@ -575,10 +575,16 @@ std::string get_image_params(SDParams params, int64_t seed) { parameter_string += "Model: " + sd_basename(params.model_path) + ", "; parameter_string += "RNG: " + std::string(rng_type_to_str[params.rng_type]) + ", "; parameter_string += "Sampler: " + std::string(sample_method_str[params.sample_method]); - if (params.schedule == KARRAS) { - parameter_string += " karras"; + if (params.schedule == KARRAS || params.schedule == AYS) { + parameter_string += " " + std::string(schedule_str[params.schedule]); } parameter_string += ", "; + if (!params.vae_path.empty()) { + parameter_string += "VAE: " + sd_basename(params.vae_path) + ", "; + } + if (params.clip_skip != -1) { + parameter_string += "Clip skip: " + std::to_string(params.clip_skip) + ", "; + } parameter_string += "Version: stable-diffusion.cpp"; return parameter_string; }