pip install diffusers --upgrade pip install invisible_watermark transformers accelerate safetensors from diffusers import StableDiffusionXLPipeline, EulerAncestralDiscreteScheduler pipe = StableDiffusionXLPipeline.from_pretrained( "hotshotco/SDXL-512", use_safetensors=True, ).to('cuda') pipe.scheduler = EulerAncestralDiscreteScheduler.from_config(pipe.scheduler.config) prompt = "a woman laughing" negative_prompt = "" image = pipe( prompt, negative_prompt=negative_prompt, width=512, height=512, target_size=(1024, 1024), original_size=(4096, 4096), num_inference_steps=50 ).images[0] image.save("woman_laughing.png")