ilkerzgi's picture
Update README.md
0e3f587 verified
metadata
license: apache-2.0
language:
  - en
tags:
  - flux
  - flux-2-klein
  - flux-lora
  - lora
  - object-removal
  - inpainting
  - image-editing
  - image-to-image
  - fal-ai
  - template:diffusion-lora
pipeline_tag: image-to-image
widget:
  - text: Remove the highlighted object from the scene
    output:
      url: examples/example1_output.jpg
  - src: examples/example1_input.jpg
    prompt: Remove the highlighted object from the scene
    output:
      url: examples/example1_output.jpg
  - text: Remove the highlighted object from the scene
    output:
      url: examples/example2_output.jpg
  - src: examples/example2_input.jpg
    prompt: Remove the highlighted object from the scene
    output:
      url: examples/example2_output.jpg
  - text: Remove the highlighted object from the scene
    output:
      url: examples/example3_output.jpg
  - src: examples/example3_input.jpg
    prompt: Remove the highlighted object from the scene
    output:
      url: examples/example3_output.jpg
  - text: Remove the highlighted object from the scene
    output:
      url: examples/example4_output.jpg
  - src: examples/example4_input.jpg
    prompt: Remove the highlighted object from the scene
    output:
      url: examples/example4_output.jpg
base_model: black-forest-labs/FLUX.2-klein-4B
instance_prompt: Remove the highlighted object from the scene
Prompt
Remove the highlighted object from the scene
Prompt
Remove the highlighted object from the scene
Prompt
Remove the highlighted object from the scene
Prompt
Remove the highlighted object from the scene

๐Ÿ—‘๏ธ Flux Object Removal LoRA

Remove unwanted objects from images with AI-powered inpainting

Try on fal.ai License

Object Removal LoRA Banner

๐ŸŽฏ What does this model do?

This LoRA removes highlighted objects from images and fills the area naturally with contextually appropriate content. Simply mark the object you want to remove, and the model will erase it seamlessly.

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                                     โ”‚
โ”‚     ๐Ÿ   ๐ŸŒณ  [๐Ÿš—]  ๐ŸŒณ  ๐Ÿ             โ”‚  Highlighted object
โ”‚         โ†“                           โ”‚  gets removed
โ”‚     ๐Ÿ   ๐ŸŒณ  ~~~~  ๐ŸŒณ  ๐Ÿ             โ”‚  and filled naturally
โ”‚                                     โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Perfect for cleaning up photos, removing distractions, and creating seamless backgrounds.


๐Ÿ–ผ๏ธ Examples

Input (with highlighted object) Output (object removed)

๐Ÿš€ Quick Start

Prompt

Remove the highlighted object from the scene

Highlighting Requirements

  • Mark the object to remove with a visible highlight/mask
  • The highlight should clearly cover the object boundaries
  • Works best with distinct, isolated objects

๐Ÿ’ป Usage

Try it Live on fal.ai

โ–ถ๏ธ Open Playground

With fal.ai SDK

import fal_client

def on_queue_update(update):
    if isinstance(update, fal_client.InProgress):
        for log in update.logs:
           print(log["message"])

result = fal_client.subscribe(
    "fal-ai/flux-2-klein/4b/base/edit/lora",
    arguments={
        "prompt": "Remove the highlighted object from the scene",
        "model_name": None,
        "loras": [{
            "path": "https://huggingface.co/ilkerzgi/flux-object-remove-lora/resolve/main/flux-object-remove-lora.safetensors",
            "scale": 1.1
        }],
        "embeddings": [],
        "image_urls": ["https://your-image-with-highlighted-object.png"]
    },
    with_logs=True,
    on_queue_update=on_queue_update,
)
print(result)

๐Ÿ“ฆ Model Files

File Use Case
flux-object-remove-lora.safetensors fal.ai
kDEkt5q7tDLKOpQJIVMPx_pytorch_lora_weights_comfy_converted.safetensors ComfyUI

๐ŸŽ“ Training Details

Click to expand

Dataset

  • Size: 100 image pairs
  • Content: Diverse scenes with objects to remove including:
    • People: individuals, groups in various settings
    • Objects: furniture, vehicles, electronics
    • Animals: pets, wildlife
    • Text: signs, watermarks, logos
    • Nature: plants, debris, unwanted elements
  • Highlighting: Objects marked for removal
  • Aspect ratios: Various (1:1, 16:9, 9:16, 4:3, 3:4, etc.)

Training

  • Base Model: FLUX.2-Klein 4B
  • Platform: fal.ai
  • Method: LoRA training
  • Steps: 4000
  • Learning Rate: 0.00005

๐ŸŽฎ Use Cases

  • Photo Cleanup: Remove photobombers, trash, or unwanted objects
  • Product Photography: Clean backgrounds for e-commerce
  • Real Estate: Remove furniture or personal items from property photos
  • Social Media: Create cleaner, more focused compositions

โš ๏ธ Limitations

  • Works best with clearly highlighted/masked objects
  • Very large objects may leave visible artifacts
  • Complex backgrounds may require multiple passes
  • Reflections and shadows of removed objects may persist

๐Ÿ“„ License

Apache 2.0


Created by @ilkerzgi โ€ข Trained with fal.ai

Try on fal.ai