Inpainting in Stable diffusion for beginners.

Поділитися
Вставка
  • Опубліковано 11 січ 2025

КОМЕНТАРІ • 93

  • @pokerandphilosophy8328
    @pokerandphilosophy8328 2 роки тому +62

    In order to get even better results, and a better integration of the new object into the picture (with an appropriate style, texture, lighting, etc.) it is best to keep the prompt as close as possible as the prompt that had been used for generating the original image. You can then just insert the description of the new object at the end of the main scenery/object description, separated with commas, just before the description of the style, lighting, artists, etc. If there are many other objects that are described in the prompt, you can delete some of the inessential ones, or just increase the weigh of the new object that you want to inpaint in order not to confuse the AI as to what you want to add. (If you merely put the bare description of the new object in the prompt, the result often looks a bit like a decal sticker had been stuck on the original image; it blends more with the immediate surrounding thanks to the mask blur, but it still clashes with the overall scenery and lighting conditions).

    • @azeemotron
      @azeemotron Рік тому

      Hi, do you think you could please write an example?

    • @time2slither307
      @time2slither307 Рік тому

      @@azeemotron I am thinking something like this.
      Original Prompt: A photo of black and white cat laying on the sand in a desert with cacti in the background, highly detailed, grainy texture, 35mm, art in the style of catman
      Inpainting prompt when adding a bowl of milk: A photo of black and white cat laying on the sand in a desert with cacti in the background, a red bowl filled with milk, highly detailed, grainy texture, 35mm, art in the style of catman

    • @Nick-vd7cg
      @Nick-vd7cg Рік тому +7

      @@time2slither307 no, delete everything an just keep artstyle of original prompt;
      inpainting prompt when adding a bowl of milk:
      a red bowl filled with milk, highly detailed, grainy texture, 35mm, art in the style of catman

    • @fluffylittlebear
      @fluffylittlebear Рік тому

      @@Nick-vd7cg That makes way more sense than what Poker and Philosophy said.

    • @lookimnotracistbut5695
      @lookimnotracistbut5695 Рік тому

      ​@@fluffylittlebear I mean he basically said the same thing just more complicated

  • @sebastiankamph
    @sebastiankamph  Рік тому

    Updated Inpainting guide here: ua-cam.com/video/No1_sq-i_5U/v-deo.html
    The FREE Prompt styles I use here:
    www.patreon.com/posts/sebs-hilis-79649068

  • @synthoelectro
    @synthoelectro 2 роки тому +9

    This is so much easier to understand. Thank you I've been fighting with inpainting since its introduction.

    • @sebastiankamph
      @sebastiankamph  2 роки тому +2

      You are so welcome! Really happy that you feel it's easier now.

  • @erickstanza8782
    @erickstanza8782 7 місяців тому

    Right, here we go, I’m a total beginner, and about to watch every single one of your videos to get caught up!

  • @Marcorios234
    @Marcorios234 Рік тому

    you are the best. There are ton of people that just say "provide png with transparent mask, it works"

  • @renzostefanmp7937
    @renzostefanmp7937 2 роки тому +1

    Thanks for the video, I just got hooked into this stable diffusion movement and needed to understand what the heck is inpainting. Subscribed and I will watch the rest of your videos.

  • @KkommA88
    @KkommA88 Рік тому +3

    Finally some decent explaining done by someone!
    Thanks, helped me out a lot on improving my images that just needed a final touch!

  • @ZeroCool22
    @ZeroCool22 2 роки тому +8

    Oh, also would be great if you explain the SCRIPTS feature of the automatic1111 UI, the "SD Upscale" is very interesting.

    • @sebastiankamph
      @sebastiankamph  2 роки тому +4

      Be happy to provide more explainer videos, I'm making them as fast as I can and will get more and more up. If people feel they're helpful I'll keep at it :) Next up will be an explainer on audio syncing AI animations automatically.

  • @kingkhalagar2836
    @kingkhalagar2836 Рік тому

    Wow watching this in the future when used to modern Sebastian is trippy, you were just a wee little baby AI artist!

    • @sebastiankamph
      @sebastiankamph  Рік тому

      Haha, so true. Production quality was lousy 😅. You think a new inpainting video is needed?

    • @kingkhalagar2836
      @kingkhalagar2836 Рік тому +1

      @@sebastiankamph I would love one, just because I struggle with it even now. Latent Noise fill never wants to agree with me. You could also cover the Out Painting A111 extension too if you wanted to since that one seems super powerful!

  • @muffanimation
    @muffanimation Рік тому

    Thank you for this !

  • @ianhmoll
    @ianhmoll 2 роки тому +4

    Great video :) Unfortunately sometimes SD don't respect inpact command and doesn't paint nothing. They should better this amazing function that already works amazinly on others. But they have limitations

  • @artofbrypaz
    @artofbrypaz Рік тому

    Very interesting …. Thanks for the explanation!

  • @Assimandeli
    @Assimandeli 2 роки тому +2

    Did everything pretty much like you did, but for whatever reason I can't get inpaint to work. Quite literally nothing happens to my image when I try to inpaint on it; it just generates the same exact picture. Any idea what might be borked on my end? SD still takes it usual amount of time "generating" the image and doesn't show any errors.

    • @THENEONGRID
      @THENEONGRID Рік тому

      Try filling instead of original and only masked instead of whole picture, or variations of these. Maybe that helps

  • @speedracer77
    @speedracer77 2 роки тому +4

    Thanks for the video. Can you make one on the correct usage of the other masked content modes? Fill, Original, Latent Nothing. I have looked all over, including the official documentation, but there still seems to be a lot of confusion. Thanks.

    • @diskomiks
      @diskomiks 2 роки тому +1

      Agrees, these functions are not covered at all

    • @sebastiankamph
      @sebastiankamph  2 роки тому

      I cover them in my ultimate guide. See my channel.

  • @Hexxgon
    @Hexxgon 2 роки тому +4

    Hey, whenever I try to generate a new image using inpainting it gives me the same thing back. It ignores the mask and my mask brush is also black instead of white. Does anyone know what the problem could be?

    • @6c3333
      @6c3333 2 роки тому

      Same for me. Have you found a solution yet?

    • @Hardts
      @Hardts 2 роки тому +1

      @@6c3333 Same, and I get the error "ValueError: Coordinate 'right' is less than 'left'" apparently, Inpainting broke right after this video was made

  • @the-entertainment477
    @the-entertainment477 Рік тому

    Do you have a tutorial about inpaint face?

  • @smyrkphace
    @smyrkphace 2 роки тому +2

    Hey in my version the inpainting UI keeps the image really small, impossible to see what Im doing. not the image scale itself, just in the UI, and no zoom option. Any ideas

    • @pokerandphilosophy8328
      @pokerandphilosophy8328 2 роки тому +2

      There is a zoom option, sort of. It's a function of your browser. While your mouse pointer is within the UI area, press down the ctrl key and scroll up with the mouse wheel. It will magnify every element of the interface, including the image. You can then scroll back down when you're done. This of course works just the same with any web page.

  • @freedom_aint_free
    @freedom_aint_free 2 роки тому +1

    Is there any domain specific languages to describe precisely what we want in a scene? If not we desperately need it!

  • @moogleking
    @moogleking Рік тому

    Good tutorial

  • @hmm-m
    @hmm-m Рік тому

    when i see "localhost" in the browser - do i understand correctly it's like u said "installed" so it work 100% locally not sending data to the internet?

  • @DanKetchum007
    @DanKetchum007 2 роки тому +1

    Lol. Turns out I've been doing inpainting completely wrong. Thanks.

    • @sebastiankamph
      @sebastiankamph  2 роки тому +1

      Happy to hear the guide helped! What was it that fixed it for you?

    • @DanKetchum007
      @DanKetchum007 2 роки тому

      @@sebastiankamph I was doing the prompt for the inpainting wrong.

    • @evilgibson
      @evilgibson 2 роки тому

      thanks as well. my problem was thinking fill was what I wanted to add something like "fill with your prompt"

  • @ZeroCool22
    @ZeroCool22 2 роки тому +1

    In Masked Content, isn't better to always use "Original", instead of the other options?

    • @sebastiankamph
      @sebastiankamph  2 роки тому +1

      Thanks for asking, it depends a little bit of what's there originally. My experience, and of those I've talked with, is that latent noise gives most consistent results, especially when there is no guide to work from (like in the case here, where there's just water). If you paint a crude sketch of a boat and img2img or inpaint from that, that's a different story. Would love to hear your experiences and why you prefer original! This is new to all of us and we're all learning as fast as we can.

  • @MugiwaraRuffy
    @MugiwaraRuffy Рік тому

    Hey everyone. I got a big problem with Inpaint where I need help. I mean, the concept sounds simple enough. Create a mask, enter a prompt, let SD do the job.
    Problem is: I don't getting it to work what so ever. In the last couple of hours, I read and watched half a dozen tutorials (including this video) on the topic. But no matter what picture I use, what prompt and worst of all independent of all the different settings, I always get the very same result: A blurred area where the mask was. And I don't know what's wrong. Or what I am doing wrong? tried to recreate and experiment with every setting I saw in those tutorials.
    Example
    1. I let SD create a TXT2IMG with a simple prompt: "empty room with a table". SD gave me exactly what I asked for, so far, so good.
    2. I took this picture to the IMG2IMG / Inpaint tab. I even copied over the seed key
    3. I want to let SD draw "a big book" onto the table. So I paint a mask of the area, where SD shall add "a big book". Again, I tried for hours experimenting with the differen settings.
    4. The result is always the same: Just a blurred area where the mask was. No big book. Or whatever.
    I am going nuts here, please help!

  • @pkay3399
    @pkay3399 Рік тому +1

    Thank you! Is there a workflow for using inpainting on the generated images and then use the Video/Animation option to interpolate?

  • @kait3n10
    @kait3n10 2 роки тому +1

    Thanks! Btw, how are you viewing the rendering process as it happens? My version (latest Automatic1111 WebUI) shows the final result only.

    • @mattaaron79
      @mattaaron79 2 роки тому +1

      In settings, look for "Show show image creation progress every N sampling steps. Set 0 to disable."

    • @kait3n10
      @kait3n10 2 роки тому

      @@mattaaron79 this is such a neat feature. Thanks :)

  • @jzonkel
    @jzonkel 2 роки тому +1

    my stable diffusion doesnt have the option for uploading mask, why?

    • @RonnieMirands
      @RonnieMirands Рік тому +1

      Mine as well, seens the interface changed. I guess...

  • @peterbrandt7456
    @peterbrandt7456 2 роки тому

    Hi, I am using the latest version of Automatic1111 but can't seem to find anywhere to load an external mask. Has this feature been removed?

  • @BeginsWithTheEnd
    @BeginsWithTheEnd 2 місяці тому

    i can't follow any of these tutorials because my webui looks completely different from everyone else's, there is no section of tabs where it says "inpaint a part of an image"

  • @pelidesachilles824
    @pelidesachilles824 Рік тому

    how can you make it so it shows the iterations/steps where it creates the ship? When I use stable diffusion I only get to see the final result

  • @void2258
    @void2258 Рік тому

    How do you subtract from the mask? I can only make more mask, not remove overspill.

  • @kyky7kyle7
    @kyky7kyle7 Рік тому

    Can someone link that tutorial on how to install this? It didn't popup when he said it

  • @apocalypsed
    @apocalypsed 2 роки тому +1

    Does anybody know how to upload a mask? What format do I use with Krita or Gimp?

  • @romainpallot9484
    @romainpallot9484 Рік тому

    Hi ! do you know if can i get the same result in my mask, but changing my image reference? i tried to take the same seed, but doesn't work :/ I try to do this to inpaint a image suite, to convert in video. Thanks for your answer and for your videos !

    • @sebastiankamph
      @sebastiankamph  Рік тому

      Hey, not following your question. Feel free to hop on Discord and ask in #help with image references to explain further.

    • @romainpallot9484
      @romainpallot9484 Рік тому

      @@sebastiankamph Thanks for your answer, yes i'm going to send on discord, se if i can find some help !

  • @AndyHTu
    @AndyHTu 2 роки тому

    When I try inpainting, it keeps giving me a blurred area that I masked out. My mask is black as well, so not sure thats why? I don't really know how to not make my mask not black.

    • @sebastiankamph
      @sebastiankamph  2 роки тому

      Yeah, sorry, not sure what might be wrong ;(

  • @monser4582
    @monser4582 2 роки тому

    How to change mark color ?

  • @ikarosound2504
    @ikarosound2504 Рік тому

    There is a way to inpaint your own image?

  • @Hubertoser
    @Hubertoser 2 роки тому

    I have a question. It seems my window has some issue for inpainting. The upper few inch are not targetable, and my mouse lose the target if i move down. I also cant paint the space i want it's always on the wrong hight. What could that be.
    I does not go away after restart.
    The paint space is is smaler as the actual window.

    • @sebastiankamph
      @sebastiankamph  2 роки тому

      Do you use a size other than 512x512? Sometimes that can create errors.

    • @Hubertoser
      @Hubertoser 2 роки тому

      @@sebastiankamph I use now an 1024x1024. And oddly the problem is gone. The 512 have the issue.🤔

    • @Hubertoser
      @Hubertoser 2 роки тому

      @@sebastiankamph Found the Issue. Do not use the Microsoft Edge browser...

  • @genin69
    @genin69 Рік тому +1

    has inpaiting in SD changed at all? cause this totally does not work anymore..

    • @sebastiankamph
      @sebastiankamph  Рік тому

      I got a new video on inpainting going up today. Small differences, but no huge changes.

    • @genin69
      @genin69 Рік тому

      @@sebastiankamph thanks for the reply.. will check it out.. btw, are there any ways to do this as described in this video ua-cam.com/video/t7b91-fr09A/v-deo.html is it possible to do this in auto1111? cause i would be very keen to draw my own shapes and then use that as reference for whatever i want to simulate but cant seem to find way to do that

    • @genin69
      @genin69 Рік тому

      @@sebastiankamph oh snap. Wait a moment.. I just figured it out! mind blown..

  • @natsuschiffer8316
    @natsuschiffer8316 2 роки тому

    Hey Sebastian,thanks for the great video
    I had a question about the masks,
    What I want to do is only to create the prompt I want without a background, while using a png image transparent in some parts.
    For example, a transparent man is the image I have, and I want a crown on his head, I paint his head or make a mask for it, prompt " a golden crown" and the crown is looking good, but SD always fills the background with random stuff.
    Always creates a background for me even if I upload my own mask, is there a workaround you know?

    • @sebastiankamph
      @sebastiankamph  2 роки тому

      Try playing around with the mask blur settings. If that doesn't help, I'd take the new hat and manually mask out the background in Photoshop above your initial image. Let me know if you find a better solution.

  • @gfortes
    @gfortes Рік тому

    what gpu you use?

  • @HrRezpatex
    @HrRezpatex Рік тому

    ships, yes, but not one of them looked like a Viking ship..
    Still, it was a good explaining of how the program work. 🙂

  • @DioVayne
    @DioVayne 2 роки тому

    Not trying to embarrass you, but what does "t and p" stand for? 😅

  • @Vitaliy_zl
    @Vitaliy_zl Рік тому

    but how to remove objects?

  • @AutumnPeir
    @AutumnPeir Рік тому

    Your interface looks different than mine.

  • @TheGalacticIndian
    @TheGalacticIndian 2 роки тому +1

    Argh! My eyes hurt with all that bright-backgroundness!

    • @HanSolocambo
      @HanSolocambo 2 роки тому +2

      fuck yeah. Each and every app installed on my Windows (and there are tons of'em) has a dark theme. Can't understand how some people can till stand those unbearable pure white backgrounds.

  • @Crazy_Comedy_0024
    @Crazy_Comedy_0024 2 роки тому

    .☮️.✌️.

  • @VoidExileYT
    @VoidExileYT 2 роки тому

    The way you said automatics. I think it would sound less Swedish if you said Automadics and didn't emphasize anything. Your Swedish dialect is very obvious

    • @sebastiankamph
      @sebastiankamph  2 роки тому +2

      Yes, I love being Swedish.

    • @VoidExileYT
      @VoidExileYT 2 роки тому

      @@sebastiankamph It's nice, but not the language. Couldn't we have just used English instead?

    • @gmalivuk
      @gmalivuk 2 роки тому +1

      Bro are you really complaining that a Swedish guy sounds Swedish?

    • @VoidExileYT
      @VoidExileYT 2 роки тому

      @@gmalivuk Apparently

  • @MonkeyButtGamer
    @MonkeyButtGamer 3 місяці тому

    is it possible to save image form mask, when even i try and save i get the white circle that you draw the mask with.