Dmitrii Tochilkin Profile picture
Aug 21 8 tweets 4 min read
Inpainting mode in #DiscoDiffusion!
I've finally made the parametrised guided inpainting for disco, and applied it for more stable 2D and 3D animations. In the thread i show what's in there

colab.research.google.com/github/kostari…
Inpainting can be used to repaint unwanted parts of the still image using binary mask. Mask can be drawn inside colab if you check 'draw_mask' flag, or by specifying the path.
I've also applied inpainting to the 2D and 3D animation processes to make them more stable. Previously we've had a tradeoff: either a stable animation with high skip_steps (but you get trails and poor details in the regions that were missing in the previous frame)
...or low skip_steps but then the animation is very shaky. Instead, we can dynamically calculate the missing part for the current frame camera movement and ✨inpaint✨only that. So, you get stable animation AND good details. 2D example:
It works for 3D animations also!
Actually, it can also be used for Video Source animation to make stable&detailed warps (by inpainting only occluded areas). But my current implementation works on top of @devdef's consistency checks from the #warpfusion patreon colab, so probably it will remain closed for now
How Disco Diffusion inpainting works: it messes up the diffusion process, enforcing the pixels outside of the mask to match the original image mixed with the amount of noise that corresponds to the current diffusion step.
Also, there is an option to add blur to the mask edges for smooth blending. The whiter the mask, the more diffusion steps is applied to this area. On the 'skip_steps' step # we start inverse-diffussing the area where mask=1, and then continuously expand for less bright areas

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Dmitrii Tochilkin

Dmitrii Tochilkin Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us on Twitter!

:(