From 61bbb4c39af39dc3c10a3214b9149c2833bdb02f Mon Sep 17 00:00:00 2001 From: sanj <67624670+iodrift@users.noreply.github.com> Date: Fri, 28 Mar 2025 09:42:17 -0700 Subject: [PATCH] Auto-update: Fri Mar 28 09:42:17 PDT 2025 --- pony.py | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 pony.py diff --git a/pony.py b/pony.py new file mode 100644 index 0000000..3b42eff --- /dev/null +++ b/pony.py @@ -0,0 +1,27 @@ +import torch +from diffusers import StableDiffusionXLPipeline, AutoencoderKL as AKL, EulerAncestralDiscreteScheduler + +# vae = AutoencoderKL.from_single_file(VAE_FILE_PATH, torch_dtype=torch.float16) + +vae = AKL.from_single_file( + "https://huggingface.co/LyliaEngine/Pony_Diffusion_V6_XL/blob/main/sdxl_vae.safetensors", + torch_dtype=torch.float16 +) + +pipeline = StableDiffusionXLPipeline.from_single_file( + "https://huggingface.co/LyliaEngine/Pony_Diffusion_V6_XL/blob/main/ponyDiffusionV6XL_v6StartWithThisOne.safetensors", + vae=vae, + safety_checker=None, + torch_dtype=torch.float16, +).to("cuda") + +pipeline.scheduler = EulerAncestralDiscreteScheduler.from_config(pipeline.scheduler.config) + +image = pipeline( + prompt="score_9, score_8_up, score_7_up, score_6_up, score_5_up, score_4_up, source_furry, beautiful female anthro shark portrait, dramatic lighting, dark background", + negative_prompt="bad quality, score_3, score_2, score_1", + height=1024, + width=1024, + num_inference_steps=25, + guidance_scale=8.5, +).images[0]