Coder Social home page Coder Social logo

Comments (9)

entusiastaIA avatar entusiastaIA commented on June 7, 2024

Further observations show that the more variables you change, from checkpoint to using hires fix the more likely it is to happen, or so it seems. When you click generate without HRF active on the same configuration it is much more rare than if using HRF or across different models.

from unprompted.

entusiastaIA avatar entusiastaIA commented on June 7, 2024

Update: my template used the shortcode [chance] only in two places over 107 files. Removing them make it much more stable. Yet changing the model or altering other non-related variables makes it tend to change the rng hence still being non-deterministic. Even without changing anything else it still is not deterministic (just hitting generate without changing anything can still output different images, although it is rarer after removing "chance" shortcode). I tried changing Automatic RNG to CPU and GPU, none of them seem to matter at all.

from unprompted.

ThereforeGames avatar ThereforeGames commented on June 7, 2024

Hi @entusiastaIA,

Thank you for bringing this to my attention.

So far, I haven't been able to reproduce the problem in my tests - I've tried running a few of my own templates at a batch_count of 10 and the images always come back the same.

I will experiment with [chance] and some other WebUI settings to see if I can figure out what the underlying issue is.

from unprompted.

entusiastaIA avatar entusiastaIA commented on June 7, 2024

So far, without using Hires Fix and without changing any model it barely ever happens. I use 16 batch count and I'd say that only one of every 8-10 times one or two images end up having different prompts.
However if I activate Hires fix it starts haoppening more often, and if I also change to use SDXL from using my 1.5 based model (Requiem) it happens almost always: some of the pictures end up with different prompts, while some retain them.

It's a very weird behaivour... I have noticed that most of the times (but not always either) is just one specific part of the prompt (the first "half") the one that stops being deterministic, while the end is still the same that it was before. However for the life of me I don't see anything special or different on my code in those parts... And sometimes it is the whole prompt anyway.

The same about the images themselves... sometimes from a 16 grid only one or two images in the middle are changed but after them the new generated images are again back the same they should be. However some other times once one image is different, all the images after that one are changed as well...

So is a really weird behaivour... these days I'm actually working trying to narrow the issue at the same time that I clean my code (as I admit it was full of workarounds and dirty patches), but so far the only thing that my code has left depending on RNG are "[choose]" and "[choose _weighted]" so I doubt there's much more I can do on my end, but if you think any specific test could be worth it, tell me so.

I think, but this is really hard to proof, that the problem is that at some point some of the [choose] (or other RNG elements) lose, change or have a problem with the seed they should be using, but after them, all the next RNG retains their numbers, that's why only certain parts of the prompts and images get affected while the rest retain their expected prompts. However, since in my template, some "choose" CAN lead to other "choose" but it is not something that always happens; if the seed changes in a way that causes one of this branching elements to be altered (be it cutting previously existing branch or adding a new branch), then all the following rng get screwed because they now happen at different places...

If as I suspect is actually a low chance event for every independent rng decission, then depending on how many of those your templates have you may need more or less images to make it happen. I could try later to build a simple code filled with rng and calls to try force it happening.

Thank you very much for your time, this is a big issue for me, hindering a lot the workflow, because I need deterministic image grids to compare the specific prompt and model changes I'm making, and definetly it wasn't happening at older versions of Unprompted and Automatic.

from unprompted.

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.