Hugging Face's logo Hugging Face
  • Models
  • Datasets
  • Spaces
  • Buckets new
  • Docs
  • Enterprise
  • Pricing
    • Website
      • Tasks
      • HuggingChat
      • Collections
      • Languages
      • Organizations
    • Community
      • Blog
      • Posts
      • Daily Papers
      • Hardware
      • Learn
      • Discord
      • Forum
      • GitHub
    • Solutions
      • Team & Enterprise
      • Hugging Face PRO
      • Enterprise Support
      • Inference Providers
      • Inference Endpoints
      • Storage Buckets

  • Log In
  • Sign Up

hc0
/
RefRes

Image-to-Image
Diffusers
lora
image-restoration
face-restoration
super-resolution
reference-based
qwen-image-2.1
Model card Files Files and versions
xet
Community

Instructions to use hc0/RefRes with libraries, inference providers, notebooks, and local apps. Follow these links to get started.

  • Libraries
  • Diffusers

    How to use hc0/RefRes with Diffusers:

    pip install -U diffusers transformers accelerate
    import torch
    from diffusers import DiffusionPipeline
    from diffusers.utils import load_image
    
    # switch to "mps" for apple devices
    pipe = DiffusionPipeline.from_pretrained("Qwen/Qwen-Image-2.1-Turbo", dtype=torch.bfloat16, device_map="cuda")
    pipe.load_lora_weights("hc0/RefRes")
    
    prompt = "Turn this cat into a dog"
    input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png")
    
    image = pipe(image=input_image, prompt=prompt).images[0]
  • Notebooks
  • Google Colab
  • Kaggle
  • Local Apps Settings
  • Draw Things
RefRes / assets
2.9 MB
Ctrl+K
Ctrl+K
  • 1 contributor
History: 3 commits
hc0's picture
hc0
Replace example images with the new comparison (with vs without RefRes)
ce71ddf verified 13 days ago
  • example_man_vs_nolora.jpg
    1.14 MB
    xet
    Replace example images with the new comparison (with vs without RefRes) 13 days ago
  • refres_cover.jpg
    177 kB
    xet
    New teaser video and cover (man example, Qwen-Image-2.1 + RefRes) 13 days ago
  • refres_teaser.mp4
    1.4 MB
    xet
    New teaser video and cover (man example, Qwen-Image-2.1 + RefRes) 13 days ago
  • refres_zone.png
    181 kB
    xet
    RefRes v5 for Qwen-Image-2.1 / Qwen-Image-2.1-Turbo 13 days ago