Git Product home page Git Product logo

Comments (25)

seijihariki avatar seijihariki commented on August 15, 2024 1

If you have any other ideas for implementation, please tell us so we can try!

For now, will implement a slider for blur, but that's the only thing that we can do for now.

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024 1

Yeah a gaussian blur slider would be great 🙏🏼 (even better if changing the slider would change the image in real time)

In real time... would be kind of difficult, considering now we have multiple concurrent generations/image picking. This pull will include a non-realtime implementation, but will see what I can do in the future.

from openoutpaint.

zero01101 avatar zero01101 commented on August 15, 2024

i suspect you're running into the decoupled reticle/SD resolution, which is actually by design but has a PR and related issue which optionally syncs the resolution to the cursor and vice versa.

with the current main-branch version (v0.0.9.6), if you expand the stable diffusion settings and set the resolution value to match your reticle size, does the output match your expectations?

[edit]
reread your issue and realized i might have missed the more important point, but just tried and was unable to confirm locally - all unmasked regions stay exactly the unmodified resolution that they're meant to...
image
image
image
image
image

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

Try inpainting a 1920x1080 image. Then choosing 1024px square, inpaint, then download the canvas. Now open the original and the new canvas images in your pc’s photo gallery and quickly switch between the two and focus on the image where the square was. Do you not see a lower res in the new canvas compared to the original? Download the two images I uploaded and quickly switch between them using your pc’s photo viewer, you’ll see a clear degradation in quality for the new canvas

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Have you changed generation resolution as well as cursor size when inpainting?

from openoutpaint.

zero01101 avatar zero01101 commented on August 15, 2024

[instructions] Do you not see a lower res in the new canvas compared to the original?

honestly, i sure don't in my output :/ no argument that there's a significant difference in your screenshots at all however

first image was an imported 1920x1080 screenshot just simply as-is using the save canvas button, second was, uh, after turning the opponent into a ""football"" with the color brush, third is a pathetic attempt to get a hot dog out of the oppopnent using the mask brush lmao
2022-12-13 05 10 28 openOutpaint image
2022-12-13 05 18 37 openOutpaint image
2022-12-13 05 24 06 openOutpaint image

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

Have you changed generation resolution as well as cursor size when inpainting?

You mean this right? I get horrible inpainting results if I increase this value. I think because the inpainting model has been trained on 512x512 images so it's best not to change this value (try keeping a fixed seed and compare the generations between 512 vs 768 or 1024 res and you'll see that 512 is the best by far)
2022-12-13 20_08_04-openOutpaint 🐠

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

[instructions] Do you not see a lower res in the new canvas compared to the original?

honestly, i sure don't in my output :/ no argument that there's a significant difference in your screenshots at all however

first image was an imported 1920x1080 screenshot just simply as-is using the save canvas button, second was, uh, after turning the opponent into a ""football"" with the color brush, third is a pathetic attempt to get a hot dog out of the oppopnent using the mask brush lmao 2022-12-13 05 10 28 openOutpaint image 2022-12-13 05 18 37 openOutpaint image 2022-12-13 05 24 06 openOutpaint image

Yeah there's no degredation in quality for the pics you uploaded. Hmm. Are you sure you increased the Dream (D) canvas size from 512px to higher (while keeping the resolution, which is under 'Stable Diffusion Settings' at 512 resolution) ?

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

Are you sure you're increasing the canvas size? Watch this vid, this is what I'm doing exactly: https://streamable.com/zv7wpi

I attached before generation and after generation pics below. You can see a clear degredation in quality of the stuff that was inside the box (download the two pics and quickly switch between the two to see the difference)

Before:
207233117-58f7bde7-9a21-482a-a24b-ccd312926c53 (1)

After:
2022-12-13 16 18_10 openOutpaint image

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Have you changed generation resolution as well as cursor size when inpainting?

You mean this right? I get horrible inpainting results if I increase this value. I think because the inpainting model has been trained on 512x512 images so it's best not to change this value (try keeping a fixed seed and compare the generations between 512 vs 768 or 1024 res and you'll see that 512 is the best by far)

Yeah, so that's the thing... We cannot really keep the generation resolution the same and increase the cursor without losing quality in the process, as we are effectively generating the image in 512x512 and scaling it up to the final resolution using just normal image scaling.

If you are refering to the unmasked regions (that should not be modified) we can see and try a fix, manually keeping these areas.

But for the actual region expected to be modified/inpainted, keeping same resolution as input is impossible, unless we we run the upscaling function in the mix. But at that point upscaling should actually be its own tool.

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

If you are refering to the unmasked regions (that should not be modified)

"If you are refering to the unmasked regions (that should not be modified)" yup that's exactly what i'm referring to. I understand the masked region will be a little lower res and that's fine, but if you can add an option to keep the unmasked regions completely the same that would be perfect!

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Maybe you should give full resolution inpainting a try, but as in this case it has no context outside of the area being inpainted, you need to be more specific with your prompts.

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

If you are refering to the unmasked regions (that should not be modified)

"If you are refering to the unmasked regions (that should not be modified)" yup that's exactly what i'm referring to. I understand the masked region will be a little lower res and that's fine, but if you can add an option to keep the unmasked regions completely the same that would be perfect!

That makes sense... Will check what it would take to implement this. Probably will only really apply to fully opaque masking to avoid dealing with averaging the images. Would that be okay to you?

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

If you are refering to the unmasked regions (that should not be modified)

"If you are refering to the unmasked regions (that should not be modified)" yup that's exactly what i'm referring to. I understand the masked region will be a little lower res and that's fine, but if you can add an option to keep the unmasked regions completely the same that would be perfect!

That makes sense... Will check what it would take to implement this. Probably will only really apply to fully opaque masking to avoid dealing with averaging the images. Would that be okay to you?

Yup that would be good, thanks a lot

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

This is not a bug anymore, but a feature request. We have to implement a feature to reapply masked surfaces to the image received from the remote before displaying them to the user (probably controlled by a checkbox or something). - Keep-masked maybe?

from openoutpaint.

zero01101 avatar zero01101 commented on August 15, 2024

yeah, i definitely missed the context of 512px render resolution with the larger reticle, my fault on that one, and agreed it shouldn't replace anything that isn't masked, but yeah, as mentioned, stable diffusion itself is just working off of a 512x512 area at that point and we're simply replacing the previous high-res content with the new low-res response...

as a crappy workaround for now, you could put the wrong-resolution masked inpaint/img2img on a new layer and erase away the undesirable bits?
lil bad pokerface

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Hi, @mpmo10, can you check if the implementation is okay for this feature? It's on the testing branch (git checkout testing).

An option was added, and is enabled by default, where all fully masked pixels on the original image are kept.

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

Hi, @mpmo10, can you check if the implementation is okay for this feature? It's on the testing branch (git checkout testing).

An option was added, and is enabled by default, where all fully masked pixels on the original image are kept.

Tried it just now, yes perfect! thanks a lot. But I do notice that when I have "Keep Masked" off, it does a better job at blending in the edges of the masked with unmaked. But when the "Keep Masked" is turned on, you can see the lines of where the mask brush has been more clearly. Is there a way to make it blend in more when "Keep Masked" is turned on? I tried increasing the "Mask blur" to 20 but even at that high value the edges of the masked and unmasked parts don't blend in that well as when "Keep Masked" is off. And going higher than 30 Mask blur makes the inpainting generations worse for some reason

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Well, that's kind of to be expected, as we have a very crisp original image right beside an area of the image that was generated at low res.

We can try adding a keep image blur slider if you want, but it will be a simple gaussian blur, so I do not guarantee that it will be anywhere near good.

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

Well, that's kind of to be expected, as we have a very crisp original image right beside an area of the image that was generated at low res.

We can try adding a keep image blur slider if you want, but it will be a simple gaussian blur, so I do not guarantee that it will be anywhere near good.

Yeah a gaussian blur slider would be great 🙏🏼 (even better if changing the slider would change the image in real time)

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Check now the testing branch.

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

Check now the testing branch.

2022-12-15 20_25_25-openOutpaint 🐠

Is it supposed to be here? I've selected the Dream (D) button, not the img2img (i) button

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

Can you open the console, disable caching and reload the page? It should have a slider under keepMasked.

from openoutpaint.

seijihariki avatar seijihariki commented on August 15, 2024

I imagine you ran git pull already.

from openoutpaint.

mpmo10 avatar mpmo10 commented on August 15, 2024

I imagine you ran git pull already.

Aha ok I see it. Yess it does work. Thanks for adding this feature!!

from openoutpaint.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.