News for hackers. Stuff that matters.
Re:Humans are biased. Generative AI is even worse by SamoyedFurFluff on Friday October 06, 2023 @11:15AM (#37791900)
I don’t think Stable Diffusion is made to produce statistically accurate depictions of groups. Asking for a judge 300 times won’t give you 34% female judge images, it will give you individual photos of the demographic most likely to be a judge, which is white male. I do agree this statistically results in exaggerated stereotypes though, I just don’t know how you would get generative images to produce while remembering what they’ve produced in the past and making it representative of the whole population of inputted images.
Re:Humans are biased. Generative AI is even worse by Swizec on Friday October 06, 2023 @11:26AM (#37792058)
I don’t think you need to remember what you’ve produced in the past to create a representative sample. There’s no global counter of male/female babies making sure we have a balanced population either.

Wouldn’t something like isMale*P(male=.66) work fine?

Re:Humans are biased. Generative AI is even worse by SamoyedFurFluff on Friday October 06, 2023 @11:42AM (#37792266)
I guess my curiosity is, what happens if you asked 300 individual artists(representative of the population) to produce a judge?
Re:Humans are biased. Generative AI is even worse by rando_dfad on Friday October 06, 2023 @11:46AM (#37792324)
I wonder where you would put that in the prompt?

I wonder how you would generalize this?

The issue is the command "draw a judge" shows a white guy 100% of the time.

if you automate prompt generation to be "draw a {gender} judge", with as you suggest the term gender has 66% chance of being "male", sure.

But how do you extend that automated prompt generation to include "draw a {skin color} judge" or "draw a {gender}, {skin color} judge".

or to occasionally generate a character from the Book of Judges.

Or Judge Dread.

Re:Humans are biased. Generative AI is even worse by _Nat_ on Friday October 06, 2023 @11:46AM (#37792331)
> Wouldn’t something like isMale*P(male=.66) work fine?

It doesn't think like that.

If it did, they could've just done `P(hasFiveFingersPerHand)=0.99999`.

But it doesn't even necessarily draw what you ask it to. Instead, it generally adopts a set of de-noising transforms that it's been trained to believe would tend to lead to what the prompt sounds like.. then whatever those transforms produce would, hopefully, be sorta like what was requested.

And it's not just the stuff about the person that affects their skin-color. For example, the scenery around a person can affect their skin-tone. Ditto for their clothing and the scene's lighting and drawing style and such.

Re:Humans are biased. Generative AI is even worse by Der_Einzige on Friday October 06, 2023 @12:00PM (#37792487)
Custom loss functions absolutely work and work basically the way described above.

https://colab.research.google.com/drive/1dlgggNa5Mz8sEAGU0wF...

You can see them define a custom color loss and apply it simultaneously with the regular diffusion loss. I've actually expanded this notebook to allow regional specification of the custom loss.

It's quite difficult to define a function that detects if an individual has 5 fingers or not. That's the real issue.

Re:Humans are biased. Generative AI is even worse by _Nat_ on Friday October 06, 2023 @12:27PM (#37792850)
It seemed like some folks thought that StableDiffusion picked, say, the race of a doctor when it started the image-generation process. This is, the comment I'd responded to seemed to have thought that StableDiffusion picked what the race of a doctor would be, then they wanted to modify its internal odds.

My point was that it doesn't actually think like that. That, for example, it doesn't even necessarily draw a human at all when the prompt asks for a doctor; instead, it de-noises and the results moreso emerge than are precisely selected.

That said, you're right that we can add more code to try to guide things.

We could even just brute-force it by just re-generating images over-and-over, or tweaking them after generation, until they match exactly what we wanted.

Re:Humans are biased. Generative AI is even worse by Swizec on Friday October 06, 2023 @08:01PM (#37797847)
My point was more that you can add these guardrails without having to keep track of what the model had previously generated.

And I think if you used a perfectly balanced dataset for training, you’d get these guardrails for free because the right probabilities would be baked into the model’s weights.

Re:Humans are biased. Generative AI is even worse by _Nat_ on Friday October 06, 2023 @08:45PM (#37798040)
Yeah, the idea to use random-selection instead of keeping track of generation-history seems reasonable. The idea of guardrails from perfect-balancing seems less obvious to me.

For example, say someone wants to generate a "US President" -- what would the ideal range of outputs be?

The article checked for just two things: sex (male or female) and skin-tone (I, II, III, IV, V, or VI). To date, all US Presidents have been male, and they were probably mostly skin-tones I or II (not bothering to check), except for Obama who was probably.. like IV or something (still not bothering to check).

So if we run StableDiffusion for a "US President", what would a "perfectly balanced" output look like? Should there be any women? What about the skin-tone distribution?

Also, Obama was a 2-term President, so.. if his skin-tone should somehow affect the distribution, should it have a stronger effect because he was in office for longer than average? Or should all US Presidents have the same effect regardless of their time in office? And either way, why?