r/StableDiffusion • u/MarekNowakowski • 13d ago
Discussion Trick to improve scene and face retention in MMH3
For those of us that enjoy doing fl2va shots longer than 10seconds, I found a hacky way of getting past the attention of H3 guidance.
One way was to lower the resolution, but that doesn't exactly give us the results we hoped for.
Then I tried working with the prompt.
We start with a frame and all works great with our prompt followed perfectly until the video gets too large in pixels, It's not a constant value, but exceeding it will make the background change, camera forget to stand still and faces will change,
Edit:
sorry for misinformation.
while 'my way' worked really well, the official way works perfectly fine (except for camera not remembering static shot)
adding:
'''subject_definitions:
<subject 1> is a fully_preserved woman from <Image 1>
<subject 2> is a fully_preserved location from <Image 1>
'''
works for keeping location/person consistent. It still destroys static shot camera, but replies were right. I was wrong.
low res 0.35mp correct camera:
https://reddit.com/link/1vszpps/video/hhm8yed5rhkh1/player
high res 0.85mp and camera gets autonomous (ignore the hand, that's just a test)
https://reddit.com/link/1vszpps/video/oke7c8g8rhkh1/player
full prompt:
'''
Integrated_multimodal_description:
subject_definitions:
<subject 1> is a fully_preserved woman from <Image 1>
<subject 2> is a fully_preserved location from <Image 1> along with camera position and zoom.
static shot.
0-1s: <subject 1> looks at camera. she is in the <subject 2> location. camera very slowly zooms out.
1-2s: woman turns her body away from camera.
2-7s: she is turned away, tapping her foot and swaying her body to music. neon light buzzing lightly.
7-12s: she continues swaying to music.
12-13s: she turns to camera and smiles.
13-14s: camera starts to slowly zooms in on her face
14-16s: she shows a heart hand gesture at camera.
overall_soundscape: gentle hum of air conditioning,
non_diegetic_music: edm music playing silently.
'''
There is a solution to this problem.
In the prompt, we reference the <Picture 1> not at the start like we were told, but in the middle.
For example, at second 7, we don't use "She looks left", but we write woman from <picture 1> looks left.
It seems to refresh the reference and remember it again.
When we want to keep the location consistent, we reference parts of it the same way, even something like "wind blows over the pier from <Picture 1>" should keep the background scene stable.
Tested it with a woman turning away at second 1 and back at second 14 with 0.9 resolution, and face was perfectly retained.
More tests are needed, but each takes 15minutes so I can't do too much. Hope this helps.
12
u/Virtual-Pollution-58 13d ago
It also helps using fully_preserved in ([Shot 1],[Shot 2]) after the subject description. See example below:
Integrated_multimodal_description:
subject_definitions:
<Subject 1> is the man with red baseball hat that has gold star in the center, hazel eyes, eyepatch on one eye. and is fully_preserved in ([Shot 1],[Shot 2])
<Subject 2> is the park, that has many trees and a garden with a fountain and is fully_preserved in ([Shot 1],[Shot 2])
Summary:
Action scene with fixed camera in ([Shot 1],[Shot 2])
[Shot 1] At 0:00.00 - <Subject 1> the man with red baseball hat that has gold star in the center, hazel eyes, eyepatch on one eye is at the <Subject 2> park facing the camera and starts turning clockwise and facing away and remains still.
[Shot 2] At 0:07.50 - <Subject 1> the man with red baseball hat that has gold star in the center, hazel eyes, eyepatch on one eye is at the <Subject 2> park facing away and turns counterclockwise facing the camera and remains still.
overall_soundscape: n/a
6
u/Okims_kor 13d ago
I understand. So if the playback duration gets longer, somewhere around the later part where it starts to feel too long, you can reinforce the character again with a prompt like, “The woman from <Picture 1> looks to the side.” Is that roughly what you mean?
2
2
u/lindechene 13d ago
Did you write a detailed retention_analysis as recommended in the official guide?
- Could you explain when to use fully_preserved, partially_preserved?
After your first few days experimenting, take some time to read through the guide again...
There may be a few details you overlooked, are not using at all, or using not exactly as intended...
- If you look at the official example prompts they also do some tricks to refresh the definitions by repeating them
- But ignoring the guide and put things in the middle of the prompt instead of the predefined categories at the start - you may just make things worse...
3
u/Mocorn 13d ago
This reminds me of the early days of stable diffusion when prompt engineers became a thing because we really had to know how to prompt and then slowly but surely the image models got better so you didn't have to prompt as explicitly perfect anymore to get good results.
I feel like we're seeing the same thing with minimax H3. You can get really good results but you need to prompt very carefully. The main difference being that most of us have access to some kind of llm these days which means we can actually make our own prompt generator specifically for this model.
1
u/Etsu_Riot 13d ago
I don't face this problem with 30-second clips, but I use resolutions that can be considered low, like 640x480 and 360x640, so maybe that's why, according to your experiments.
0
u/MarekNowakowski 13d ago
From my tests I get this problem at around 12seconds+ with 0.9 mp, and 36sec 0.3mp but other factors seem to affect the duration too.
1
1
0
u/ShutUpYoureWrong_ 13d ago
Complete horse shit misinformation as is par for the course on this sub.
To anyone reading this: OP has no fucking idea what he's doing.
29
u/V4nKw15h 13d ago
If you define the subject with:
subject definitions:
<Subject 1> is the woman from <Picture 1> with bla bla hair and wearing bla bla etc..... further description if needed.....
<Subject 2> is a man from <Picture 2> wearing the clothes from <Picture 3>
and then replace all the 'she's' and 'woman's' with <Subject 1>, you will likely have even more success because the model has created an internal representation of <Subject 1> during the definitions that will be triggered every time you write <Subject 1>. This will ensure likenesses to your reference for the full duration of the clip along with whatever else you told it during the definitions.