comfyanonymous / ComfyUI

The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface.
https://www.comfy.org/
GNU General Public License v3.0
57.58k stars 6.1k forks source link

Mangled Workflow in PNG #4002

Open gonzalu opened 4 months ago

gonzalu commented 4 months ago

Expected Behavior

Proper Workflow saved in the PNG

Actual Behavior

Older workflow not related to actual workflow used to generate the image

Steps to Reproduce

Run workflow. Image is saved multiple times throughout the workflow at different stages Load any of the images to reload workflow Wrong workflow loads

Debug Logs

UI has been restarted multiple times since problem occurred. I believe the workflow is actually just mangled with both workflows embedded ...

Other

I posted in the Discord debug channel but felt it was important to post here for the broader user base/community

https://discord.com/channels/1218270712402415686/1244085343905648691/1260779285887713392

mcmonkey4eva commented 4 months ago
gonzalu commented 4 months ago

Thank you... I just updated to the latest version via Manager and I made this video to show the problem persists

https://www.youtube.com/watch?v=ZKyo0N0qgfs

gonzalu commented 4 months ago

Here is one of the last saved images...

ComfyUI__00005_

gonzalu commented 4 months ago

and here is what the actual workflow should look like:

image

gonzalu commented 4 months ago

240711101918_%EffLoader base_ckpt_name%_%KSmpBASE seed%_%KSmpBASE sa_%KSmpBASE steps%_%KSmpBASE cfg%_FaceDetailer_00001

gonzalu commented 4 months ago

Mangled Workflow Working Version 01 workflow.json

gonzalu commented 4 months ago

Mangled Workflow NON WORKING Version 02 workflow.json

gonzalu commented 4 months ago

ORIGINAL SOURCE file with working workflow.

I am trying to recover the workflow that was mangled as it had important updates to it with additional functionality ...

https://i.ibb.co/wRdXW96/Comfy-UI2x-Sharpened-00001.png

gonzalu commented 4 months ago

Is there a way I can recover the good part of the workflow and discard the bad?

gonzalu commented 4 months ago
  • Update comfyui to latest, there were recently workflow mangling bugs that got fixed
  • if updating doesn't fix it right away, please post the relevant image(s) to test replication with

Any news?

I don't have experience with JSON or the Comfy metadata but I do believe the two workflows are in the file. I just need to salvage the parts that matter to me and the rest can be discarded.

Thanks for your help

IrfanKheiri commented 2 months ago

i noticed that the png files saved are huge >10MB. I have to forego saving png with embedded workflow because of this.

ltdrdata commented 2 months ago

i noticed that the png files saved are huge >10MB. I have to forego saving png with embedded workflow because of this.

PNG does not support lossy compression, so high-resolution images can become quite large in file size. The workflow itself becomes large only in very exceptional cases, such as when using a custom node that stores the image itself in the workflow in base64 format.

gonzalu commented 2 months ago

...or in my case, having multiple note nodes with thousands of prompts LOLOL ...

IrfanKheiri commented 2 months ago

but before a certain update all my files were under 2MB (png) all of a sudden the same workflow started creating huge png images when i save them through the save image node.

ltdrdata commented 2 months ago

but before a certain update all my files were under 2MB (png) all of a sudden the same workflow started creating huge png images when i save them through the save image node.

What is the workflow?

gonzalu commented 2 months ago

but before a certain update all my files were under 2MB (png) all of a sudden the same workflow started creating huge png images when i save them through the save image node.

What is the workflow?

I posted my images above with the embedded mangled workflow ... if you want to take a look.

ltdrdata commented 2 months ago

but before a certain update all my files were under 2MB (png) all of a sudden the same workflow started creating huge png images when i save them through the save image node.

What is the workflow?

I posted my images above with the embedded mangled workflow ... if you want to take a look.

Has your workflow's saved image size, which used to be small, become enormous after an update?

gonzalu commented 2 months ago

The problem above was quite a long time ago :( I have updated comfy and all nodes a hundred times probably since then :D

Should I try loading it again now with latest or will it make no difference?

I know the workflow is just mangled because when I manually look at it in notepad, I see both workflows co-mingled in there. I just wanted to recover one of the workflows because I did not have a copy of it otherwise.

Thank you

IrfanKheiri commented 2 months ago

but before a certain update all my files were under 2MB (png) all of a sudden the same workflow started creating huge png images when i save them through the save image node.

What is the workflow?

I posted my images above with the embedded mangled workflow ... if you want to take a look.

Has your workflow's saved image size, which used to be small, become enormous after an update?

yes same workflow with the save image node as before the update. Now makes saved image size huge (png only)