receyuki / comfyui-prompt-reader-node Goto Github PK
View Code? Open in Web Editor NEWThe ultimate solution for managing image metadata and multi-tool compatibility. ComfyUI node version of the SD Prompt Reader
License: MIT License
The ultimate solution for managing image metadata and multi-tool compatibility. ComfyUI node version of the SD Prompt Reader
License: MIT License
I read one previous report with this issue, but op said he had complicated workflow. Also response suggested using Prompt Saver to save metadata w images.
I'm trying to read metadata from previously generated (ComfyUI) png images. The only node I have in my workspace is the Prompt Reader yet still get this error.
Start with clean, clear workspace
Load only the Prompt Reader node
Load image, either from slider or by upload
Queue Prompt
error generated
Selecting any other format aside from png results in error (png works just fine) (latest build):
Error occurred when executing SDPromptSaver:
[Errno 2] No such file or directory: '00001.webp'
File "C:\Stable Diffusion\GUIs\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Stable Diffusion\GUIs\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Stable Diffusion\GUIs\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Stable Diffusion\GUIs\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\nodes.py", line 386, in save_images
piexif.insert(metadata, str(file))
File "C:\Stable Diffusion\GUIs\ComfyUI_windows_portable\python_embeded\Lib\site-packages\piexif_insert.py", line 32, in insert
with open(image, 'rb') as f:
^^^^^^^^^^^^^^^^^
No response
1.0.0
Currently, the SD Parameter Generator node allows the definition of both the Positive and Negative Aesthetic Score values, particularly important for SDXL Refiner. However, these two values are not printed as part of the Parameters output generated by the node.
Would it be possible to add them to the output (perhaps, between the Scheduler and the Size outputs)?
Positive aesthetic score: 6.00
Negative aesthetic score: 2.50
No response
I have removed all other custom nodes, thinking that it might be a conflict with another one, but it continues to fail installation.
### Loading: ComfyUI-Manager (V1.25.2)
### ComfyUI Revision: 1881 [af94eb14] | Released on '2024-01-06'
FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json
FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/extension-node-map.json
Traceback (most recent call last):
File "/Users/username/AI/ComfyUI/nodes.py", line 1810, in load_custom_node
module_spec.loader.exec_module(module)
File "<frozen importlib._bootstrap_external>", line 850, in exec_module
File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
File "/Users/username/AI/ComfyUI/custom_nodes/comfyui-prompt-reader-node/__init__.py", line 1, in <module>
from .nodes import NODE_CLASS_MAPPINGS, NODE_DISPLAY_NAME_MAPPINGS
File "/Users/username/AI/ComfyUI/custom_nodes/comfyui-prompt-reader-node/nodes.py", line 35, in <module>
from .stable_diffusion_prompt_reader.sd_prompt_reader.image_data_reader import (
File "/Users/username/AI/ComfyUI/custom_nodes/comfyui-prompt-reader-node/stable_diffusion_prompt_reader/sd_prompt_reader/image_data_reader.py", line 185
match image_format:
^
SyntaxError: invalid syntax
Cannot import /Users/username/AI/ComfyUI/custom_nodes/comfyui-prompt-reader-node module for custom nodes: invalid syntax (image_data_reader.py, line 185)
Import times for custom nodes:
0.0 seconds (IMPORT FAILED): /Users/username/AI/ComfyUI/custom_nodes/comfyui-prompt-reader-node
No response
First, thank you for the node suite. I've been playing with it the last few days and it screams "must-have batch tool for upscaling workflow from low-quality rushes/seed images".
The abilty to load images with their metadata is awesome, especially when - like me - you use wildcards a lot.
But when we design an upscaling workflow, we most likely want it to support batch loading.
I tried the obvious way with "convert image to input" on the reader but I couldn't find any node able to link to this "image" input.
Abillity to connect image loaders to SD_Prompt_Read node.
No response
If I generate an image with a workflow that includes the SDParameterGenerator
node (like the AP Workflow or the default ComfyUI workflow in the image below), and I later drag that image into the ComfyUI canvas, or Load it via the floating menu, all generation parameters are correctly loaded except the seed value. That remains to -1.
SDParameterGenerator
nodeError occurred when executing SDPromptReader:
invalid literal for int() with base 10: 'None'
File "C:\Users\rober\Downloads\AI Creations\ComfyUI\execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\rober\Downloads\AI Creations\ComfyUI\execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\rober\Downloads\AI Creations\ComfyUI\execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\rober\Downloads\AI Creations\ComfyUI\custom_nodes\comfyui-prompt-reader-node\nodes.py", line 161, in load_image
seed = int(
^^^^
I use impact wildcard nodes for my prompt strings/wildcards. Can I assume this is incompatible with the prompt reader?
This workflow was attempting to load an image that I have genned with verifiable metadata using the batch loader connected to the prompt reader.
No response
No response
(Not sure if this is a bug or just me doing it wrong)
I have created a bunch of images with SD Prompt Saver. Each one has a different prompt. Now I would like to further process them in a batch using the prompt retrieved by SD Prompt Reader. But it seems I can only load the images individually and manually. Connecting the SD Batch Loader and SD Prompt Reader gives a runtime error.
Having the ability to use the original prompt in batch processing would be tremendously useful for the community, it would be really great if you have an answer to this!
No response
No response
Right now the SD Parameter Generator
node exports a VAE. Great, but it doesn't allow to define which one. Usually, this is a task for the Checkpoint Loader, as in the following case, with the Efficient Loader
node:
but, given that the use already has to define the type of model (SD1, SD2, SDXL), it would be convenient to have the VAE selector (mainly useful for SD1.5) baked into the Parameter Generator.
Just like the dropdown in my screenshot above.
No response
I don't really know if it's a bug, but I'll report nonetheless.
A few users of the AP Workflow lament that, once downloaded it, they are unable to Queue any generation job. The Queue button does nothing, and there's no error message in the terminal.
So, to investigate, I cleared the canvas, loaded the default ComfyUI workflow, and added the SDParameterGenerator
node.
From that moment on, even without connecting the SDParameterGenerator
node to the default KSampler, my Queue button stopped working.
As soon as I remove the SDParameterGenerator
node from the default workflow, the Queue button restarts working as expected. No need to restart ComfyUI or reload the workflow.
It took me 30 minutes to figure out that the only way to fix this is that, once you add the SDParameterGenerator
node to the default workflow, you need to refresh the browser for the Queue button to start working as expected.
I don't know what's causing this but I thought that it's perhaps connected to the problem that the AP Workflow users lament.
SDParameterGenerator
node to the workflow. It doesn't matter if it's properly configured or even connected to anything.SDParameterGenerator
node from the workflow. The Queue button should work again as expected.SDParameterGenerator
node from the workflow. The Queue button should do nothing.SDParameterGenerator
node is still present in the workflow).I'm considering different approaches to reduce the number of wires in the AP Workflows without sacrificing understandability of the information flow.
Among the other things, I'm evaluating the use of Impact Pack's Image Sender
and Image Receiver
nodes.
I would place an Image Sender
node after each image generation node (e.g., KSampler, Detailers) and an Image Receiver
node just before every SD Prompt Saver
node.
My test shows that the latter don't play well together.
After a KSampler
node generates the image, it passes it to the Image Sender
node, which correctly passes it to the Image Receiver
node. However, the Image Receiver
node doesn't seem to pass the image to the SD Prompt Saver
node as expected:
I am not married to the idea of using Impact Pack's Image Sender/Receiver nodes at all costs. I'd just like to have the SD Prompt Saver
to wirelessly receive the image to save, if possible.
See screenshot.
No response
Hello,
I'm loving this node set, and one thing I'd like to have is the ability to pass in a string to the prompt saver node that would get filled in as a placeholder. This way I could craft custom strings that I wanted to be part of a filename. Currently I've just modified scheduler_str
back into existence and use %scheduler
to do this, but it would be nice to not redo this any time I update.
I don't know whether the node should handle filename sanitation or leave that up to the user, though.
Example: I want to make a series of images with a specific theme that gets passed into the prompt, e.g. "cyberpunk". I would pass this string into the prompt saver node as an input, say "custom", then set an output filename of %date_%custom_%counter
to get 2024-02-02_cyberpunk_00001.png
No response
I generated a image by comfyui-portrait-master
After I loaded the image with comfyui-prompt-reader-node , got error
1ใAdd the SD Prompt Reader node to your workflow.
2ใDrag and drop an image (generated from a previous workflow and otherwise unmodified) into the SD Prompt Reader node.
3ใhit "Queue Prompt,"
4ใerror:
'list' object has no attribute 'strip'
File "/opt/ComfyUI/execution.py", line 155, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
File "/opt/ComfyUI/execution.py", line 85, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
File "/opt/ComfyUI/execution.py", line 78, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
File "/opt/ComfyUI/custom_nodes/comfyui-prompt-reader-node/nodes.py", line 156, in load_image
image_data = ImageDataReader(f)
File "/opt/ComfyUI/custom_nodes/comfyui-prompt-reader-node/stable_diffusion_prompt_reader/sd_prompt_reader/image_data_reader.py", line 45, in __init__
self.read_data(file)
File "/opt/ComfyUI/custom_nodes/comfyui-prompt-reader-node/stable_diffusion_prompt_reader/sd_prompt_reader/image_data_reader.py", line 105, in read_data
self._parser = ComfyUI(
File "/opt/ComfyUI/custom_nodes/comfyui-prompt-reader-node/stable_diffusion_prompt_reader/sd_prompt_reader/format/comfyui.py", line 42, in __init__
self._comfy_png()
File "/opt/ComfyUI/custom_nodes/comfyui-prompt-reader-node/stable_diffusion_prompt_reader/sd_prompt_reader/format/comfyui.py", line 84, in _comfy_png
File "/opt/ComfyUI/custom_nodes/comfyui-prompt-reader-node/stable_diffusion_prompt_reader/sd_prompt_reader/format/comfyui.py", line 85, in
self._negative_sdxl.get(key).strip()
No response
When generating more than one image in ComfyUI, the SD Prompt Saver only saves the last image.
It shows the correct number of images, but each image is the same last image (if batch = 4, you'll see 4 times the last image in the preview)
1.0.0
Having a file name output on the file reader would be nice and path to the file would be nice
Having the file name and path lets you easy place the new image in the same folder and make a text file with comments or information named the same as the new image for easy sorting
No response
When this node is enabled I encounter strange behaviour from the search dialog. From the search dialog, when clicking upon the top right dropdown control (which has things like LATENT, MODEL, CLIP, etc in it) i encounter anomalous behaviour. First the desktop locked up, graphical artifacts spans over the screen. Restarting the shell let me try again. This time clicking the control displays the normal items but also has appended:
STRING
INT
FLOAT
*
euler,euler_ancestral,heun,heunpp2,etc...
normal,karras,exponential,sgn_uniform,etc...
No response
filename & path
%counter cannot be used for path, it can only be used for filename. This %counter is slightly different from the %counter in the built-in Saver node, it will count all image files in the path.
I know it's hardly imposible to please everyone. But I would like to have a counter in the path, like %date/%counter/
, so that I can keep my renders separately, it's much easier for my workflow. Is there any workaround to achive this (not manually)?
With this extension loaded, the background-double click menu to add a node becomes much wider than the screen. Removing it and restarting comfyui show this menu in regular behavior.
Both Comfyui and prompt-reader-node are up to date on my end.
No response
1.0.0
I have a lot of images in different formats, but all the names starts with the counter. If possible, I'd like for SD Prompt Saver to calculate the value of %counter taking into account other images in the folder
Let's say I have next files:
00034 something something.jpg
00134 something something.png
01097.webp
And I have only %counter as a filename in the SD Prompt Saver node. I'd like it to save next generated picture with the name
01098.png
(png or any other format)
PS: thank you for your hard work!
SDPromptMerger throws an error when fed empty strings
Error occurred when executing SDPromptMerger:
list index out of range
File "D:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 143, in recursive_execute
input_data_all = get_input_data(inputs, class_def, unique_id, outputs, prompt, extra_data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 27, in get_input_data
obj = outputs[input_unique_id][output_index]
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
No response
it loads checkpoint every time despite checkpoint not changed.
No response
No response
File "L:\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\nodes.py", line 27, in
from .stable_diffusion_prompt_reader.sd_prompt_reader.constants import (
ModuleNotFoundError: No module named 'comfyui-prompt-reader-node.stable_diffusion_prompt_reader.sd_prompt_reader'
Cannot import L:\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node module for custom nodes: No module named 'comfyui-prompt-reader-node.stable_diffusion_prompt_reader.sd_prompt_reader'
Traceback (most recent call last):
From what I can tell, it seems like if I do a batch of X > 1 with SD Batch loader, it uses the same prompt for all of the images in the batch (the first image)
No response
No response
Re-adding this request, though I found it but it's just a text input.
Requesting a proper image pipeline into the prompt reader so that we can feed images generated in the workflow straight into it for metadata parsing.
generate image > parse metadata > use metadata
No response
Add VAE to list prompt reader/saver
Please add the VAE (name) to the prompt reader/saver (as an optional)
No response
Just wanted to say congratulations for this package, it's amazing to have all parameters in (almost) one node.
I only miss Clip Skip
to complete the whole thing. Have you ever think about it?
Thank you this marvellous job.
Clip Skip in SD Parameter Generator.
No response
I feel like the only person running into this, since no one has mentioned it here so far, but whenever I drag an image or manually choose an image for the prompt reader node, the boxes stay blank. It can populate with the wrong information if changing images, causing problems if the user isn't aware that the prompt info doesn't match the current image. I added steps into the Reproduction Steps that you can follow.
Here's what it ends up looking like. It displays information from the wrong image.
Sorry if I'm doing something stupid. I'm on ComfyUI: 1930d1533d.
No response
There is an exception message "'NoneType' object has no attribute 'endswith'" after updating ComfyUI
ComfyUI: When using %counter in the filename, it will overwrite existing images. Basically %counter will reset to 0 everytime you queue up a render.
Result : When you queue X iterations with Batch_Size = Y, you will have Y images at the end, with %counter values from 0 to Y
Suggestion : have it work like the basic SaveImage node, where you supply the path&filename, and the counter is automatically added and incremented based on existing images with that filename at target path.
No response
No response
1.3.4
Windows
A1111's webUI
SDPromptReader node :
I got this error also i tried JPG,PNG images:
https://i.gyazo.com/3eb9df3545280bedb9b4b2fb91811a2c.png
Error occurred when executing SDPromptReader:
No data detected or unsupported format
File "D:\dev\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\dev\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\dev\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\dev\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\nodes.py", line 159, in load_image
raise ValueError(MESSAGE["format_error"][1])
Error occurred when executing SDPromptReader:
No data detected or unsupported format
File "D:\dev\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\dev\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\dev\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\dev\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\nodes.py", line 159, in load_image
raise ValueError(MESSAGE["format_error"][1])
No response
No response
Single images work fine, increasing batch size results in multiplying results, 2x2, 3x3, etc. So a with a batch size set to 4 you get 16 images being processed in SD Prompt Saver, there's also a problem with filename output sanitation, error related:
Error occurred when executing StringFunction|pysssss:
'list' object has no attribute 'replace'
File "D:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Custom-Scripts\py\string_function.py", line 43, in exec
out = text_a.replace(text_b, text_c)
^^^^^^^^^^^^^^
Similar issue seems to occur with SD Prompt Merge when using null strings that I already posted about.
Very often, I find myself in need of adding a note to the image generation I'm about to queue. It could be a reason why I am doing a certain test, or the purpose of the image, or just to indicate how what was the tool that generated that image.
Accordingly, I manually add a Multiline Text
node next to the SD Parameter Generator
node, and then push output that text to both the debug section of my workflow and to the Extra Info
input of the SD Prompt Saver
node (see screenshot below).
It works perfectly fine, but it's a lot of extra nodes and wires that we could probably avoid if this field would be part of the SD Parameter Generator
node.
I propose the creation of this field as the very last input box (if possible), and the very last output pin, in the node.
I think it's still within the scope of this node and it would be a QoL improvement.
Thank you for considering it.
No response
Save Checkpoint and LoRA information in civitAI compatible format from the CivitAI nodes.
This is just about the only feature I feel like I'm missing now, at the moment I'm forced to use cute-comfy to save full civitAI compatible metadata including all checkpoints and loras used. However cute-comfy has it's own limitations because it's not a node but listener so it has no ability to tell it exactly which metadata to record if using unsupported nodes.
The civitAI nodes can be populated with AIR codes that are civitAI compatible for linking resources.
No response
I don't remember if we previously discussed this feature in another issue and I was told that due to the limitations of the engine, it's impossible to achieve. I'll just create its own issue here for consideration and documentation.
The problem is that, for logging and debugging purposes, I would like to export (via print or save to file) the full filename generated by SD Prompt Saver
node, according to the configuration decided in the node.
If an export wouldn't be possible, at least, I wish the node would print the generated filename in the terminal on its own. It's not ideal, but it's better than nothing.
Let's say that the SD Prompt Saver
is configured as follows:
I would want to see an exported line (or a line printed in the terminal) that says:
Saved file: 465801832038646_2023-10-25_143039_base.png
No response
I know we already discussed this, and I tested the current approach extensively in these weeks since you released the new version of Parameter Generator.
My conclusion is that it's really difficult to remember what each ratio means in terms of pixels from the current drop down:
And since the node shows the exact pixels only after queuing a generation, it's a game of guesses, or googling the answer before using ComfyUI, or bookmarking posts like this one. At least, that's what I do now.
It would be really super useful if the node would show each pixel pairing next to each ratio (and according to the selected SD family).
model_version
drop down.aspect_ratio
drop down.No response
I just released AP Workflow 6.0 with the SD Parameter Generator. Everything works fine, except when I try to test the new LCM sampler with the LCM models:
This configuration generates the following error:
Error occurred when executing SDParameterGenerator:
'model.diffusion_model.input_blocks.0.0.weight'
File "xyz/ComfyUI/execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "xyz/ComfyUI/execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "xyz/ComfyUI/execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "xyz/ComfyUI/custom_nodes/comfyui-prompt-reader-node/nodes.py", line 603, in generate_parameter
checkpoint = comfy.sd.load_checkpoint_guess_config(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "xyz/ComfyUI/comfy/sd.py", line 431, in load_checkpoint_guess_config
model_config = model_detection.model_config_from_unet(sd, "model.diffusion_model.", unet_dtype)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "xyz/ComfyUI/comfy/model_detection.py", line 141, in model_config_from_unet
unet_config = detect_unet_config(state_dict, unet_key_prefix, dtype)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "xyz/ComfyUI/comfy/model_detection.py", line 49, in detect_unet_config
model_channels = state_dict['{}input_blocks.0.0.weight'.format(key_prefix)].shape[0]
From what I read, LCM is fully compatible with Apple MPS, I wonder if it's an issue with the node itself.
No response
No response
1.0.0
First: it took me countless hours over an entire week to pinpoint this behavior. Yet, I am not sure this is a bug. It might be that I don't understand well enough the intricacies of ComfyUI. With that in mind, here's the problem:
When the Model
output of an SD Parameter Generator
node is passed to an Efficient KSampler
node, whatever LoRA has been defined in a Efficient Loader
node gets ignored.
Recreate the following situation:
As you can see in this example, the Cartoon_SDXL_V2
LoRA is completely ignored by the Efficient KSampler
node if I use the Model
output generated by the SD Parameter Generator
node.
However, if I use the Model output coming straight from an Efficient Loader
node, the LoRA is correctly applied:
In both cases, notice this is an img2img workflow simply VAE Encoding a source image.
If this is not a bug, but the expected behaviour, it makes impossible for me to use this portion of the SD Parameter Generator
node in the AP Workflow, so I really hope it's a bug.
Thank you!
Output when the Model comes from SD Parameter Generator
:
Output when the Model comes from Efficient Loader
:
Example image: https://pasteboard.co/FfcxUpdd5JTB.png
Image settings: "Steps: 40, Sampler: DDIM, CFG scale: 7, Seed: 610501910, Size: 768x768, Model hash: 2c02b20a"
The model parameter is missing which I think is the cause of the issue.
Error from console:
ERROR:root:!!! Exception during processing !!!
ERROR:root:Traceback (most recent call last):
File "/mnt/nvme2tb/github/ComfyUI/execution.py", line 154, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
File "/mnt/nvme2tb/github/ComfyUI/execution.py", line 84, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
File "/mnt/nvme2tb/github/ComfyUI/execution.py", line 77, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
File "/mnt/nvme2tb/github/ComfyUI/custom_nodes/comfyui-prompt-reader-node/nodes.py", line 173, in load_image
self.param_parser(image_data.parameter.get("model"), parameter_index)
File "/mnt/nvme2tb/github/ComfyUI/custom_nodes/comfyui-prompt-reader-node/nodes.py", line 207, in param_parser
data_list = data.strip("()").split(",")
AttributeError: 'NoneType' object has no attribute 'strip'
No response
In ComfyUI I get this error for all created images when I run SD prompt reader.
Error occurred when executing SDPromptReader:
'dict' object has no attribute 'strip'
File "[my path]\ComfyUI_windows_portable\ComfyUI\execution.py", line 153, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "[my path]\ComfyUI_windows_portable\ComfyUI\execution.py", line 83, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "[my path]\ComfyUI_windows_portable\ComfyUI\execution.py", line 76, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "[my path]\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\nodes.py", line 125, in load_image
image_data = ImageDataReader(f)
^^^^^^^^^^^^^^^^^^
File "[my path]\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\stable_diffusion_prompt_reader\sd_prompt_reader\image_data_reader.py", line 45, in __init__
self.read_data(file)
File "[my path]\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\stable_diffusion_prompt_reader\sd_prompt_reader\image_data_reader.py", line 100, in read_data
self._parser = ComfyUI(
^^^^^^^^
File "[my path]\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-prompt-reader-node\stable_diffusion_prompt_reader\sd_prompt_reader\format\comfyui.py", line 42, in __init__
self._comfy_png()
File "[my path]ComfyUI\custom_nodes\comfyui-prompt-reader-node\stable_diffusion_prompt_reader\sd_prompt_reader\format\comfyui.py", line 72, in _comfy_png
self._positive.strip(),
^^^^^^^^^^^^^^^^^^^^
No response
1.0.0
Node output of model/checkpoint name as string
When trying to generate similar images, different checkpoint could have been used, it automates the selection of checkpoint.
No response
In SD Parameter Generator, the refiner_start parameter always rounds to the tens.
0.3 = 30%
0.2 = 20%
0.25 = 30%
If a want to generate with 100 total steps, and start the refiner at 25, right now it's not possible (it rounds to 30).
No response
Extractor for most additional options and new nodes:
Name String: Sampler
Name String: VAE
Int: Clip skip
Boolean: Pad conds
I would like to thank you for your work, and I have a few suggestions for additions.
Extractor for Additional Options:
Of course, the names of VAEs and models can sometimes be unhelpful if they are, for example, in folders. Therefore, I would suggest creating a new node that searches the folders with the given name and, if found, automatically returns the entire path to that model, for example, "Anime/anime_v10.safetensor" and pass to Checkpoint Selector.
Similarly, for the names of samplers, there should be an additional node that extracts the sampler_name from the string and pass to Sampler Selector as well as the scheduler and pass to Scheduler Selector.
If you think that dealing with names and their additional node converters would be too much work, I would mainly request the output for Clip skip and Pad conds.
No response
There's an "Extra Info" field in the Prompt Saver, but that field doesn't seem to exist in the Prompt Reader.
No response
No response
I updated all custom nodes and installed SD-Prompt Reader Node and then restarted ComfyUI.
I cleared the workspace and added the SD Prompt Reader Node and then selected a jpeg file dowloaded from Civitai. Loading that file in the stand alone app or on the ComfyUI workspace shows the prompts and metadata of the image.
However, uploading it into the SD Prompt Reader Node, displays the image at the bottom of the node, but doesn't fill the prompt boxes nor does it activate any of the outputs.
1.0.0
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.