g-diffuser-bot
g-diffuser-bot copied to clipboard
Create custom gallery viewer for outputs
The new output system is finally complete.
Build a custom output gallery browser that slurps up all the json in the outputs path and can easily browse, sort, filter, organize / tag / save, and one-click delete images.
I think this should be a single html file "web app" you can run locally by connecting to a localhost command server, or remotely by connecting to the command server by http (with token).
https://lexica.art/ would be my inspiration for what a good browser could look like, but with the above mentioned features.
It would also be a very good starting point for a general web ui.
An idea for an interface for filtering would be:
- At the top of the screen show the search / filtering interface
- In the center of the screen show all matching images for that search and filter (that aren't in your special "saved" folder)
- Left click an image to move them to a section on the right side of the screen
- Right click an image to move them to a section on the left side of the screen
- All 3 sections should be independently scrollable, and you can move things around as many times as you want
- When done hit a button and everything on the left is deleted, everything on the right is sent to a special "kept" or "saved" folder
This should be fairly reasonable when dealing with other media types that aren't images as well.

- call this image Image A, and we will call the left hand 256x512 region Chunk A (imagine the mask is a hard line straight down the middle instead of a feathered erase)
- generate an img2img with the inpaint pipeline using Chunk A as the input, it outputs a 512x512 image (Image B)
- we will call the righthand side of Image B 'Chunk B'
- take Chunk B and create a new 512x512 image where Chunk B is now on the lefthand side and the righthand side is blank
- generate an img2img with the inpaint pipeline using this new image as the input, it outputs a 512x512 image (image C)
- we will call the righthand side of Image C 'Chunk C'
Two options: Option A) when the bot is done generating Image C, it appends Chunk A to the lefthand side of Image C, resulting in a 756x512 image Option B) the gallery viewer shows Chunk A on the lefthand side of Image C without actually altering the files themselves
Option A would be easier to implement but could potentially be more of a problem with filesize if you repeat this process a large number of times with a large number of images per batch (eg generating 20 2048x512 images instead of the usual 512x512s)
This feature would allow a user to outpaint in a single direction an arbitrary number of times with a GPU that is not nearly powerful enough to generate large images, and could form the basis for a method of outpainting in multiple directions repeatedly.
Without this feature, a user would only be able to look at Chunk B and Chunk C together when they have completed step 5 in the above process. This would let them evaluate each generated output to see if the Chunk C part of each output looks good with the Chunk B, but the only way they could ALSO evaluate if all three Chunks look good together would be to manually cut and paste Chunk A onto the side of each output image from step 5, and that sounds like work. This feature would allow a user to instantly look at all 3 (OR MORE!) Chunks together at once to see which of the newly generated Chunks (the ones on the farthest right side) look the best with the Chunks that have been generated and kept thus far. When the user finds a Chunk C that looks good, they can repeat the above process to generate Chunk D, look at an image of Chunk ABCD with dozens of new Chunk Ds, with no manual cutting and pasting, meaning they can flip back and forth between several Chunk D options to evaluate which is best, and then keep repeating the process until they have a whole gosh darn alphabet of Chunks in a glorious 6656x512 image.
Chunk A
Image B featuring Chunk A on the left and Chunk B on the right
Image C featuring Chunk A then Chunk B then Chunk C
(idk why they are so bad lol)