Remove objects from photos — — Easy to use Image Inpainting

MLBoy
2 min readJan 20, 2022

An easy way to use the Image Inpainting model

Machine learning fills in the missing parts of the image.

I want to erase some objects is in the photo

There are times when something unintended is reflected in the background, or you want to erase a part of the photo.

LaMa is amazing

It’s a famous image editing software, but that function is easy to use in Python.
Lama is an inpainting library for high resolution images.

procedure

Clone the repository, install the required modules, and download the pre-trained weights.

Perform inference.

python3 bin/predict.py model.path=${pre_trained_model_path} indir=${input_images_path} outdir=${result_images_path}

You can also easily run it in Colab.

For image editing applications and designs

Once we can use it so easily, we can use it for various purposes such as design.

🐣

I’m a freelance engineer.
Work consultation
Please feel free to contact us with a brief development description.
rockyshikoku@gmail.com

I am making an app that uses Core ML and ARKit.
We send machine learning / AR related information.

GitHub

Twitter
Medium

--

--