receyuki / comfyui-prompt-reader-node

The ultimate solution for managing image metadata and multi-tool compatibility. ComfyUI node version of the SD Prompt Reader
MIT License
289 stars 22 forks source link

SD PromptSaver node adds an extra 12seconds to first run #101

Open drmbt opened 3 weeks ago

drmbt commented 3 weeks ago

Description

I'm seeing a 12 second run time that isn't there for other save nodes, and that is really hurting me when using comfy with an API. It seems like the SD PromptSaver node might actually be flushing the flux model and reloading it into memory; I'm guessing that if not using the SD ParameterGenerator, this is what you're doing to get model name, which seems really inneficient. if model name could just be a string that would be ideal, or really anything that wouldn't trigger a reload

Reproduction steps

run any basic workflow using the SD PromptSaver, take a look at the inference time reported for that node on the first run from a cold boot

Image file

first run: image second run: image first run with a dummy empty model nullModel.ckpt: image

drmbt commented 3 weeks ago

interestingly enough, if i convert model_name to an input and don't connect anything, this isn't a problem