2023-12-25 17:52:41 +01:00
2023-12-23 20:02:07 +01:00
2023-12-25 17:52:41 +01:00
2023-12-25 17:52:41 +01:00
2023-12-25 17:52:41 +01:00
2023-12-25 17:52:41 +01:00
2023-12-25 17:52:41 +01:00
2023-12-23 20:02:07 +01:00
2023-12-23 19:54:06 +01:00
2023-12-23 20:02:07 +01:00
2023-12-25 17:52:41 +01:00
2023-12-23 20:02:07 +01:00

ComfyUI-Crystools

A powerful set of tools for your belt when you work with ComfyUI

Show metadata, compare between two JSONs, compare between two images, show any value to console/display, pipes, and more!

Show metadata

Debugger

Node: Show Metadata

With this node, you will be able to see the JSON produced from your entire prompt and workflow so that you can really know all the values (and more) of your prompt quickly without the need to open the file (PNG or JSON).

Show metadata

Options
  • Active: Enable/disable the node
  • Parsed: Show the parsed JSON or plain text
  • What: Show the prompt or workflow (prompt are values to produce the image, and workflow is the entire workflow of ComfyUI)

Node: Show any value to console/display

You can practically see any text or data from the nodes. Connect it to what you want to inspect, and you will see it.

Show any

Parameters
  • Input:
  • any_value: Any value to show, can be a string, number, etc.
  • Options:
  • Console: Enable/disable write to console
  • Display: Enable/disable write on this node
  • Prefix: Prefix to console

Node: Show any value to JSON

As same the previous one, but it formatted the value to JSON (only display).

Show any

Parameters
  • Input:
  • any_value: Any value to try to convert to JSON
  • Output:
  • string: The same string is shown on display

Primitives

Nodes: Primitive boolean, Primitive integer, Primitive float, Primitive string, Primitive string multiline

A set of nodes with primitive values to use in your prompts.

Primitives

List

A set of nodes with list of values (any or strings/texts) for any propose (news nodes to use it coming soon!).

Important: You can use with others nodes like "Show any" to see the values of the list

Node: List of strings

Even you can concatenate them

Lists

Parameters
  • Input:
  • string_*: 8 possible inputs to use
  • delimiter: Use to concatenate the values on output
  • Output:
  • concatenated: A string with all values concatenated
  • list_string: The list of strings (only with values)

Node: List of any

You can concatenate any value (it will try to convert to string and show the value), so util to see several values at the same time.

Lists

Parameters
  • Input:
  • any_*: 8 possible inputs to use
  • Output:
  • list_any: The list of any elements (only with values)

Switch

A set of nodes to switch between flows.

All switches are boolean, you can switch between flows by simply changing the value of the switch.
You have predefined switches (string, latent, image, conditioning) but you can use "Switch any" for any value/type.

Switches

Pipe

Nodes: Pipe to/edit any, Pipe from any

This powerful set of nodes is used to better organize your pipes.

The "Pipe to/edit any" node is used to encapsulate multiple links into a single one. It includes support for editing, easily adding the modified content back to the same pipe number.

The "Pipe from any" node is used to extract the content of a pipe.

Important:

  • Please note that it supports "any," meaning it does not validate (not yet!) the correspondence of input nodes with the output ones. When creating the link, it is recommended to link consciously number by number.
  • "RecursionError", It's crucial to note that the flow of links must be in the same direction, and they cannot be mixed with other flows that use the result of this one. Otherwise, this may lead to recursion and block the server (you need to restart it!)

Typical example:

Pipes

With pipes:

Pipes

Editing pipes:

Pipes

Bad example with "RecursionError: maximum recursion depth exceeded":

Pipes

Image

Node: Load image with metadata

This node is the same as the default one, but it adds three features: Prompt, Metadata, and supports subfolders of the "input" folder.

Load image with metadata

Outputs
  • Image/Mask: The same as the default node
  • Prompt: The prompt used to produce the image (not the workflow)
  • Metadata RAW: The metadata raw of the image (full workflow) as string

Note: The subfolders support is by: comfyui-imagesubfolders

Node: Show resolution

This node is used to show the resolution of the image.

Can be used with any image link.

Show resolution

Node: Preview from image

This node is used to preview the image with the current prompt and additional features.

Preview from image

Feature: It supports cache (shows as "CACHED"), so you can disconnect the node and still see the image and data, so you can use it to compare with others!

Preview from image
You can see the seed, steps, and cfg were changed

Notes/features:

  • Additional feature: This node has an output as metadata raw, you can use to compare with others! (see metadata comparator)
  • Additional data: Shows the filename, resolution, datetime and size with the current prompt, not the original one! (see detail).
Sample of notes

All the data even the prompt shown is from the temporal image, not the original one! Preview from image from load image

Important:

  • If you want to read the metadata of the image, you need to use the load image with metadata and use the output "metadata RAW" not image.
  • To do a preview it is necessary save it first on temporal folder, and the data shown is from the temporal image, not the original one.
Outputs
  • Metadata RAW: The metadata raw of the image (full workflow) as string

Node: Preview from metadata

This node is used to preview the image from the metadata and shows additional data (all around this one).
It supports same features as preview from image (cache, metadata raw, etc).

Preview from metadata

Metadata

Node: Metadata extractor

This node is used to extract the metadata from the image and handle it as a JSON as source for other nodes. You can see all information, even metadata from others sources (like photoshop).

The input can be from the load image with metadata or preview from image nodes.

Metadata extractor

Other metadata sample

With metadata from Photoshop Metadata extractor

Outputs
  • Prompt: The prompt used to produce the image.
  • Workflow: The workflow used to produce the image (all information about nodes, values, etc).
  • file info: The file info of the image/metadata (resolution, size, etc) as human readable.
  • raw to JSON: The entire metadata raw but formatted/readable.
  • raw to property: The entire metadata raw as "properties" format.
  • raw to csv: The entire metadata raw as "csv" format.

Node: Metadata comparator

This node is so useful to compare two metadata and see the differences (the reason why I created this extension!)

You can compare 3 inputs: "Prompt", "Workflow" and "Fileinfo"

There are tree potential "outputs": values_changed, dictionary_item_added, dictionary_item_removed (in this order of priority).

Metadata extractor

Notes:
I use DeepDiff for that.
If you want to compare two JSONs, you can use the JSON comparator node.

Outputs
  • Diff: This is the same output you can see in the display of the node, you can use it on others nodes.

Utils

Some useful nodes to use in your workflow.

Node: JSON comparator

This node is so useful to compare two JSONs and see the differences.

JSON comparator

Node: Stat system

More info and works: ig

buscar con oo

primerp pryecto en python

todo test persistir imagen no sobrevive al f5 por mas que se vea la data agregar desde menu o doble click log persisitr data

mostrar primioro show any, creo que es por que es js puro

Installation

Install from GitHub

  1. Install ComfyUi.
  2. Clone this repo into custom_modules:
    cd ComfyUI/custom_nodes
    git clone https://github.com/crystian/ComfyUI-Crystools.git
    
  3. Start up ComfyUI.

Install from manager

Search for crystools in the manager and install it.

S
Description
No description provided
Readme MIT
16 MiB
Languages
Python 41.9%
JavaScript 32.2%
TypeScript 23.7%
CSS 1.8%
Shell 0.4%