vladmandic / automatic

SD.Next: Advanced Implementation of Stable Diffusion and other Diffusion-based generative image models
https://github.com/vladmandic/automatic
GNU Affero General Public License v3.0
5.7k stars 423 forks source link

[Feature]: Adjustable grid image creation limit #1406

Open brknsoul opened 1 year ago

brknsoul commented 1 year ago

Feature description

There's an option to prevent creation of grid images for single images.

It'd be nice to be able to customise that option to prevent creation of grid images for generations of X or fewer images.

I tend to create images 2 at a time (batch size:2) so I get a heck of a lot of grid images being created.

Version Platform Description

n/a

vladmandic commented 1 year ago

i'm not sure i understand?

brknsoul commented 1 year ago

When you start a generation of Batch Count and/or Size >1, SD will generate a grid image, located in outputs\grids. This is the first image that's displayed in the image viewer.

Essentially, I'm requesting that this option; image be expanded to not save grids of "X or fewer images" (X being an adjustable number, default '1')

vladmandic commented 1 year ago

ok, i understand now. i prefer to not have more tuneables than absolutely necessary, how about "do not save grids consisting of single batch" instead?

brknsoul commented 1 year ago

What's wrong with more tuneables? ;-)

If you implemented "do not save grids consisting of single batch" that will remove grids entirely.

The problem is, if I'm creating a batch of, say, 20 images (for comparison), I'd want a grid. Hence the adjustable number.

vladmandic commented 1 year ago

What's wrong with more tuneables? ;-)

the fact that app devolves into total mess that nobody can understand. we're already there and i'm really really trying to simplify.

imo, you either have an output grid or you dont. entire "do not save grids of single consisting of single image" is already pointless.

so when i'm talking about single batch, im refering to number of output cells. yes, i could use better terminology. if you have more than 1 output cell, its a grid and should be saved. if not, its not a grid to start with. and one cell can be single image of x if you set your batch size to x.

brknsoul commented 1 year ago

The problem is, there's a limitation to Batch Size.

As I see it, Batch Size creates size images at the same time, using more vRAM, where Batch Count 'clicks' the Generate button count times after the last Batch finishes.

Since you have this fancy new tooltip system up, you could just explain what the new setting does.

Personally, if my generation will create 2 images from a single Generate click, I don't want a grid. However, if my generation will create more than 2 images from a single Generate click, I do want a grid.

That shouldn't matter whether the Generate click creates 2 images because of Batch Count:2 or Batch Size:2. To the user, it's the same thing, I get 2 images.

vladmandic commented 1 year ago

Since you have this fancy new tooltip system up, you could just explain what the new setting does.

that is now a community effort with a well defined hints system that is publiclly editable - please join and contribute!

back to grids: the end question is grid-of-what? if end result is a grid which has x/y/z all just 1, how can you call it a grid? its not - i shouldn't care how many images are inside the cell if there is no grid. so instead of looking at how many target images were produced (as it is right now), i should be looking at how many target cells were produced.

brknsoul commented 1 year ago

I'm sorry, I must be confusing you. I'm not talking at all about the x/y/z script.

Spin up SD.Next, pop in a prompt and set the Batch Count to, say, 4. image

After generation, the image viewer shows this; image

This generates the grid image (located in outputs\grids) and each individual generation (located in outputs\text).

This is the grid image I'm talking about.

vladmandic commented 1 year ago

ahhh, that...yeah, i got it confused with xyz grid. not sure about the use case, but its already deep in settings, so sure, why not. i'll add it to backlog.

brknsoul commented 1 year ago

I'm just checking in to see if this has been added to your backlog. (I haven't noticed a backlog tag being added.)