CoolFace
Modelpublic

SkyAsl/Portrait-generator

sourceHugging Faceapache-2.0updated 10mo agoView on Hugging Face
0likes15downloads
Model Card

Model description

Portrait-generator

Portrait-generator is a LoRA fine-tuned adapter for the stable-diffusion-xl-base-1.0 model, trained on the Rapidata/Face_Generation_Benchmark dataset. It specializes in generating face images.


Usage

  1. 1.Install dependencies (if not installed):
bash
pip install diffusers transformers accelerate safetensor torch
  1. 1.Load stable-diffusion-xl-base-1.0 and LoRA adapter:
python
from diffusers import DiffusionPipeline
import torch

pipe = DiffusionPipeline.from_pretrained(
    "stabilityai/stable-diffusion-xl-base-1.0",
    torch_dtype=torch.float16,
).to("cuda")

pipe.load_lora_weights("SkyAsl/Portrait-generator")
pipe.fuse_lora()

image = pipe("a high-quality portrait of a woman").images[0]
image.save("test.png")

Metrics

  • —Average CLIPScore: 16.6980