Spaces:
Runtime error
Runtime error
title: Edit Image | |
emoji: 💻 | |
colorFrom: purple | |
colorTo: purple | |
sdk: gradio | |
sdk_version: 4.26.0 | |
app_file: app.py | |
pinned: false | |
license: apache-2.0 | |
Background_editor | |
#Setting up locally: | |
1. git clone the repo and cd into the directory ` cd Edit_image` | |
2. install the dependencies using ` pip install -r requirements.txt` | |
3. run the app file using ` gradio app.py` | |
# Approach: | |
Reference: 'https://huggingface.co/docs/diffusers/en/using-diffusers/inpaint' | |
Model used: `runwayml/stable-diffusion-inpainting` | |
1. Loading the required image | |
2. Creating a binary mask for the image | |
3. Invert the mask created | |
4. Convert the mask into an image to be passes into the model pipline | |
5. Pass the inverted mask image into the pipeline along with the prompt | |
Collab Notebook link (easier and also can use gpu for faster compute) | |
Hosted on hugging face (`https://huggingface.co/spaces/sharmaarush/Edit_image`) this might take time because running on cpu | |