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

davidfant
/
sd-ecom-brightswimwear

Image-to-Image
Diffusers
StableDiffusionInpaintPipeline
Model card Files Files and versions
xet
Community
4

Instructions to use davidfant/sd-ecom-brightswimwear with libraries, inference providers, notebooks, and local apps. Follow these links to get started.

  • Libraries
  • Diffusers

    How to use davidfant/sd-ecom-brightswimwear with Diffusers:

    pip install -U diffusers transformers accelerate
    import torch
    from diffusers import AutoPipelineForInpainting
    from diffusers.utils import load_image
    
    # switch to "mps" for apple devices
    pipe = AutoPipelineForInpainting.from_pretrained("davidfant/sd-ecom-brightswimwear", dtype=torch.float16, device_map="cuda")
    
    img_url = "https://raw.githubusercontent.com/CompVis/latent-diffusion/main/data/inpainting_examples/overture-creations-5sI6fQgYIuo.png"
    mask_url = "https://raw.githubusercontent.com/CompVis/latent-diffusion/main/data/inpainting_examples/overture-creations-5sI6fQgYIuo_mask.png"
    
    image = load_image(img_url).resize((1024, 1024))
    mask_image = load_image(mask_url).resize((1024, 1024))
    
    prompt = "a tiger sitting on a park bench"
    generator = torch.Generator(device="cuda").manual_seed(0)
    
    image = pipe(
      prompt=prompt,
      image=image,
      mask_image=mask_image,
      guidance_scale=8.0,
      num_inference_steps=20,  # steps between 15 and 30 work well for us
      strength=0.99,  # make sure to use `strength` below 1.0
      generator=generator,
    ).images[0]
  • Notebooks
  • Google Colab
  • Kaggle
sd-ecom-brightswimwear
4.35 GB
Ctrl+K
Ctrl+K
  • 2 contributors
History: 57 commits
patrickvonplaten's picture
patrickvonplaten
Fix deprecation warning by changing `CLIPFeatureExtractor` to `CLIPImageProcessor`. (#3)
13a5159 over 3 years ago
  • feature_extractor
    Upload with huggingface_hub almost 4 years ago
  • samples
    stable-diffusion-inpainting, fine-tuned from breast size, flower-garden (20000 steps) almost 4 years ago
  • scheduler
    Upload with huggingface_hub almost 4 years ago
  • text_encoder
    stable-diffusion-inpainting, fine-tuned from breast size, flower-garden (20000 steps) almost 4 years ago
  • tokenizer
    stable-diffusion-inpainting, fine-tuned from breast size, flower-garden (2000 steps) almost 4 years ago
  • unet
    stable-diffusion-inpainting, fine-tuned from breast size, flower-garden (20000 steps) almost 4 years ago
  • vae
    Upload with huggingface_hub almost 4 years ago
  • .gitattributes
    1.43 kB
    initial commit almost 4 years ago
  • args.json
    13.7 kB
    stable-diffusion-inpainting, fine-tuned from breast size, flower-garden (2000 steps) almost 4 years ago
  • model_index.json
    467 Bytes
    Fix deprecation warning by changing `CLIPFeatureExtractor` to `CLIPImageProcessor`. (#3) over 3 years ago
  • train_inpainting_dreambooth.py
    35.8 kB
    stable-diffusion-inpainting, 4/5 breast size, updated code (2000 steps) almost 4 years ago