r/StableDiffusion • u/ninjazombiemaster • 7h ago
No Workflow Self-Refining Sampler+
https://github.com/Alex240z/ComfyUI-SelfRefiningSamplerPlus



Based on: https://arxiv.org/html/2601.18577v1 and builds on pre-existing work by Kijai (The SamplerSelfRefineVideo Node).
I have found that Minimax H3-Image loves the Self-Refining Sampler. Seeing this, I spun up an improved version (SRS+) that is compatible with sampling methods besides Euler, has more easily adjustable sub-step and perturb amounts per step.
It seems to significantly improve the model's ability to resolve fine details, especially when combined with the "Empty-Image Trick" I shared previously (if using T2V). One place this is evident are patterns like fishnet, lace, sequins and other challenging fabrics/textiles. It seems to improve line-art for anime/illustration styles, and can often fix self-correct body-horror deformities.
As a starting point, try running it from steps 2-4 with 3 sub-steps and an uncertainty threshold of 0.03. But I'm much more curious what settings you try and results you get with them. Since it does sub-step, it increases gen time but I think it is well worth it.
I've tested it less with video, but it has shown promise there, too.
Just socket this chungus into a SamplerCustomAdvanced like any other sampler. Let me know if you have any issues, or what kind of results you get.
12
u/ninjazombiemaster 7h ago
Video example of it fixing a Pika H3 gen using the paper's preset:
https://imglink.cc/cdn/8oCs6N3f93.mp4
7
u/Dante_77A 7h ago edited 7h ago
Interestingly, these fishnet outfits usually glitch on most models if the character isn’t close to the camera.
But note that the girl’s face has been drastically altered
6
u/YeahlDid 5h ago
Pretty neat stuff, thank you. About how much does this add to generate time?
4
u/JorG941 2h ago
Is this aplicable on other models?
2
u/VasaFromParadise 1h ago edited 53m ago
threshold of 0.03
My image changes dramatically after this method. Has anyone figured out why yet? Or is it just me?
PS. perturb_strength_scale - must be less than 1, otherwise the image changes significantly.
2
u/nixudos 3h ago
I tried it on a 9 step Ref2video Minimax H3 workflow.
Just the default settings, as I have no idea what to tweak.
It seemed to improve the audio noticeably, but there was one artifact in it. I'm trying to make another test and see if it was just a fluke.
Are there any recommended settings for Minimax video generations?
1
u/mac404 2h ago edited 2h ago
Interesting, definitely going to try it out!
Loading it up, seems like the defaults baked into the node are different from what you're suggesting to start with in the post here? Any reason why you're setting uncertainty threshold so much lower than the 0.25 node default and running it on one fewer step? And which metric is being used (mean or norm) related to your 0.03 suggestion?
Edit: Okay, a few dumb questions as I try to make sense of the settings:
1
u/Ill_Resolve8424 2h ago
How to use this in comfy? Looks promising
1
u/Estwhy 1h ago
Im so dumb, could you provide us a workflow please?
0
u/Diabolicor 6h ago edited 5h ago
Really interesting paper. Can you describe the config you used for your video tests and did you run it with your Re-Time pass or was it just 1 Pass ?
0
u/Enshitification 2h ago
I wonder if this would combine well with the Lakonik team's pi-H3 to get better results from their low-step adapters? I'm not near a machine to test it right now, so this is my reminder note.
0
u/celialoriaart 1h ago
The difference on the fishnet texture and the hand structure in the "after" shot is wild. Definitely plugging this into my SamplerCustomAdvanced node to test those 2-to-4 step settings!
-2
u/fallengt 2h ago
Neat, but sampling speed decreases quite a bit. It's not free lunch