Skip to content

ao899/ComfyUI-APG_ImYourCFGNow

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Use this node like a RescaleCFG node, ... modelIn -> ThisNode -> ModelOut ... -> KSampler

See paper https://arxiv.org/pdf/2410.02416 for instructions about the other parameters. (Pages 20-21)

I have commented out the casting to .double() inside the function "project" as it was causing a parameter error on my machine (DirectML can't use 'double', I believe). Shouldn't cause any noticeable difference, probably.

Edit: Updated defaults, works well with high Norm_Threshold and higher scales

Edit2: Fixed a bug where momentum_buffer.running_average wouldn't reset between gens, changed defaults based on my tests again. If you tried changing resolution without triggering a re-patch, you'd see a nice error message...

Edit3 - 21/10/2024: Now the Sampler's cfg is this node's previous "scale" value. May need to refresh the workflow and recreate the node.

About

ComfyUI implementation of the paper https://arxiv.org/pdf/2410.02416 "APG".

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 100.0%