--- library_name: diffusers license: openrail++ language: - en tags: - text-to-image - stable-diffusion - lora - safetensors - stable-diffusion-xl base_model: Linaqruf/animagine-xl-2.0 widget: - text: face focus, cute, masterpiece, best quality, 1girl, green hair, sweater, looking at viewer, upper body, beanie, outdoors, night, turtleneck parameter: negative_prompt: lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, normal quality, jpeg artifacts, signature, watermark, username, blurry example_title: 1girl - text: face focus, bishounen, masterpiece, best quality, 1boy, green hair, sweater, looking at viewer, upper body, beanie, outdoors, night, turtleneck parameter: negative_prompt: lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, normal quality, jpeg artifacts, signature, watermark, username, blurry example_title: 1boy ---

Pastel Style XL LoRA

sample1
sample4
sample2
sample3

## Overview **Pastel Style XL LoRA** is a specialized LoRA (Low-Rank Adaptation) adapter, expertly designed to work in conjunction with Animagine XL 2.0. This model specifically focuses on enhancing and imparting a pastel-style aesthetic to anime-themed images. It integrates smoothly with the Stable Diffusion framework, offering a unique capability to produce images with soft, pastel-like qualities without the need for specific keywords or tags.
## Model Details - **Developed by:** [Linaqruf](https://github.com/Linaqruf) - **Model type:** LoRA adapter for Stable Diffusion XL - **Model Description:** Pastel Style XL LoRA is a compact yet potent model aimed at augmenting the output of larger models, particularly Animagine XL 2.0. It's adept at generating and modifying high-quality anime-themed images, giving them a distinctive pastel aesthetic. This model is an excellent choice for those seeking to add a gentle, pastel touch to their anime creations. - **License:** [CreativeML Open RAIL++-M License](https://huggingface.co/stabilityai/stable-diffusion-2/blob/main/LICENSE-MODEL) - **Finetuned from model:** [Animagine XL 2.0](https://huggingface.co/Linaqruf/animagine-xl-2.0)
## 🧨 Diffusers Installation Ensure the installation of the latest `diffusers` library, along with other essential packages: ```bash pip install diffusers --upgrade pip install transformers accelerate safetensors ``` The following Python script demonstrates how to utilize the LoRA with Animagine XL 2.0. The default scheduler is EulerAncestralDiscreteScheduler, but it can be explicitly defined for clarity. ```py import torch from diffusers import ( StableDiffusionXLPipeline, EulerAncestralDiscreteScheduler, AutoencoderKL ) # Initialize LoRA model and weights lora_model_id = "Linaqruf/pastel-style-xl-lora" lora_filename = "pastel-style-xl-v2.safetensors" # Load VAE component vae = AutoencoderKL.from_pretrained( "madebyollin/sdxl-vae-fp16-fix", torch_dtype=torch.float16 ) # Configure the pipeline pipe = StableDiffusionXLPipeline.from_pretrained( "Linaqruf/animagine-xl-2.0", vae=vae, torch_dtype=torch.float16, use_safetensors=True, variant="fp16" ) pipe.scheduler = EulerAncestralDiscreteScheduler.from_config(pipe.scheduler.config) pipe.to('cuda') # Load and fuse LoRA weights pipe.load_lora_weights(lora_model_id, weight_name=lora_filename) pipe.fuse_lora(lora_scale=0.6) # Define prompts and generate image prompt = "face focus, cute, masterpiece, best quality, 1girl, green hair, sweater, looking at viewer, upper body, beanie, outdoors, night, turtleneck" negative_prompt = "lowres, bad anatomy, bad hands, text, error, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality, normal quality, jpeg artifacts, signature, watermark, username, blurry" image = pipe( prompt, negative_prompt=negative_prompt, width=1024, height=1024, guidance_scale=12, num_inference_steps=50 ).images[0] # Unfuse LoRA before saving the image pipe.unfuse_lora() image.save("anime_girl.png") ```