Glossary
What is inpainting AI
In short
Inpainting AI repaints a selected part of an image: you paint an area with a mask, and the neural network fills it with new content that matches the rest of the picture.
Images, video, audio · inpainting
MMOOZZGG.com editorsChecked: 1 min read
For a child
Sometimes an ink blot lands on your favorite drawing. You can carefully cover it with a piece of paper and draw what was under it: a bit of sky, a branch, a window. If you try hard, nobody will notice the patch. A computer can fix pictures and photos the same way. You only need to show it honestly which spot to fix, and it leaves the rest alone.
In plain words
You open a photo and use a brush to paint over what is in the way: a wire in the background, a random passer-by, a stain on the tablecloth. The painted area is called a mask. The neural network looks at everything around it: colors, light, lines and textures, and draws a believable continuation inside. You can add things as well as remove them: type “a vase with tulips”, and the vase appears exactly in the painted spot. The rest of the photo stays untouched. This quickly solves tasks that used to need careful manual retouching.
For business
The method saves retouching time in catalogs, advertising and real estate: you remove extra objects from a photo, change a price tag or a sign, or fill in a missing piece of an interior. The cost depends on the volume of photos and how you run it: a cloud editor with a subscription, or an open model on your own server if product and client photos cannot leave the company. The main risk is a change of meaning. The same tool can quietly alter a document, a receipt or a photo from a site, so a company should set rules on which images may be edited and who is responsible for the edit. The second risk: the model sometimes changes the edges around the mask and distorts the product itself, so a person checks the final image.
For a specialist
Image inpainting is the restoration or replacement of pixels inside a binary mask, taking the surrounding context into account. Classic methods copied patches from nearby areas, while neural methods learn to generate the content. LaMa (Suvorov and others, 2021) uses fast Fourier convolutions, which give every layer a receptive field over the whole image, and trains on large masks; the model carries over to resolutions higher than those it was trained on. The diffusion approach RePaint (Lugmayr and others, 2022) takes a pretrained unconditional DDPM and inserts the known pixels outside the mask at the reverse steps, without fine-tuning the network. According to the diffusers documentation, white mask pixels are repainted, black ones are kept, and blurring the mask edges smooths the transition. Checkpoints trained for this task give a more natural border but more often touch the area outside the mask; if that area must stay exact, the original is placed on top of the result.
Example
A real estate agency photographs an apartment where the previous tenants left their things. A manager paints over the boxes and bags, the neural network fills in the floor and walls, and the listing says the photos were edited.
Related terms
Questions and answers
Sources
Not sure whether your company needs this?
AI solutions map