Repository navigation
0.0.4 #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
0.0.4 #10
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| # Rules about content | ||
|
|
||
| Two decisions for each part of the original: which workflow it goes into (Split), and what becomes of it (keep it, fix it, replace it with core, or remove it). Used when writing the understanding document (step 2) and when building (step 4); `canvas diff` compares the result with the original (step 8). Rules read as in readable-form.md (Why, Bad, Fine, Undecided). | ||
| Two decisions for each part of the original: which workflow it goes into (Split), and what becomes of it (keep it, fix it, replace it with core, or remove it). Used when writing the understanding document (step 2) and when building (step 4); `canvas diff` compares the result with the original against the four items of SKILL.md, step 4. Rules read as in readable-form.md (Why, Bad, Fine). | ||
|
|
||
| ## Read before deciding | ||
|
|
||
|
|
@@ -10,29 +10,34 @@ Two decisions for each part of the original: which workflow it goes into (Split) | |
| ## Split | ||
|
|
||
| **One workflow is one thing the user wants to do.** Many workflows are fine: the aim is the principles of SKILL.md, not fewer workflows. Why: 1 task = 1 workflow. | ||
| - One workflow: a generation whose stages pass conditioning or a latent on (base → refiner → Hires.fix; t2i → a redraw at a larger size with the same model). | ||
| - One workflow: a generation whose stages pass conditioning or a latent on (base → refiner → Hires.fix; t2i → a redraw at a larger size with the same model). Effects on the finished image (film grain, colour matching, frame interpolation, a 1x deblur) stay in it. | ||
| - Split: what changes what can be done (t2i, i2i and edit; T2V and I2V); what changes the sampling setup (steps, sigmas, cfg, the sampler): models each with their own settings, a speed-up that changes steps or cfg. Tasks that are not connected (outputs sharing no upstream). | ||
| - Its own workflow: effects applied to the finished image (film grain, colour correction and the like). | ||
| - A bypassed branch in the one workflow: an optional guide (a depth or reference image the task can do without), a speed-up that only may make it faster, an addition that only may make it a little better (CFGZeroStar, a guidance adjustment). | ||
| - Bad: one workflow whose switch or bypass chooses between things that must be split. Workflows split for an optional guide or an on/off branch. Of several selectable sets (models with their settings), one built as nodes and the others left as a table in a Note. Effects on the finished image packed into the generation workflow. | ||
| - A bypassed branch in the one workflow: a speed-up that only may make it faster, an addition that only may make it a little better (CFGZeroStar, a guidance adjustment). | ||
| - An added function the user may want or not (a ControlNet, a guide image) is split: with it and without it. A few nodes that must be switched together can stay in the one workflow as a group switched with bypass. | ||
| - Bad: one workflow whose switch or bypass chooses between things that must be split. Of several selectable sets (models with their settings), one built as nodes and the others left as a table in a Note. | ||
|
|
||
| Name split workflows so the version shows, give the difference in one phrase in the report, and put the same function in the same layout across them. | ||
| Put the same function in the same layout across split workflows. | ||
|
|
||
| ## What becomes of each part | ||
|
|
||
| **Keep what the author added on purpose** (processing, values, structure per stage: one seed handed across stages, a CLIP Text Encode per stage; bypassed or muted branches, the unselected side of a switch; a Compare). Merge ways of doing one step differently (Tiled VAE Decode and VAE Decode) into the one the author chose. Why: the rebuilt workflow keeps every function of the original. | ||
| **Keep what the user can do** (the functions they can choose, bypassed or muted branches, the selectable sides of a switch) and a Compare the author added; a seed handed across stages stays one seed. The way it is built (which nodes, how they are wired) is not among what is kept: what brings the same thing is rebuilt in its simplest form. Merge ways of doing one step differently that give the same result (Tiled VAE Decode and VAE Decode differ only in memory) into the one the author chose; candidates that give different results stay, switched with Branch (techniques.md). Why: the rebuilt workflow keeps every function of the original. | ||
| - Bad: a function of the original gone from every rebuilt workflow (only debugging leftovers may go). | ||
|
|
||
| **Fix what does nothing for the result or harms it, and what narrows what the user can do for no gain; report it.** Examples: a sampler whose result the next one fully redraws (both start at step 0 with noise added); VAE Encode right after VAE Decode (pass the latent on); decoding and previewing the middle of generation (techniques.md shows the form); positive and negative swapped in one of two same-shaped stages; an intermediate result saved while the final one only previews; a value that breaks the model's required multiple; a fixed size where the user should choose one. Why: the workflow does what it seems to do. | ||
| **Fix what does nothing for the result or harms it, and what narrows what the user can do for no gain; report it.** Examples: a sampler whose result the next one fully redraws (both start at step 0 with noise added); VAE Encode right after VAE Decode (pass the latent on); decoding a picture that is still being drawn (techniques.md shows the form); positive and negative swapped in one of two same-shaped stages; an intermediate result saved while the final one only previews; a value that breaks what the model or the node itself asks for (a multiple, or sizes that must match, as its tooltip or source says). Why: the workflow does what it seems to do. | ||
| - Bad: one of these left in the rebuilt workflow. | ||
| - Fine: a value the author may have chosen on purpose (a hand-made sigma list, a strength) is kept; if it looks strange, it is explained in a Caution Note (notes.md). This is for values only: a strange way of wiring (the positive and the negative encoded through different CLIP chains) is fixed. | ||
| - Fine: a value that changes the result (a hand-made sigma list, a strength) is kept even when it looks strange, and is explained in a Caution Note (notes.md). A stage or node that does nothing for the result, or whose result is redrawn later, is fixed even when the author seems to have put it there on purpose, and the report says so. A value that differs from what the author's own words (a node title, a Note) say it is is a slip, not a choice: it is set to what they say, and the report says so. A value is fixed only when something written shows it is wrong (the author's own words, or what the model or node asks for); the report names it. Without that, it is the author's choice. This is for values only: a strange way of wiring (the positive and the negative encoded through different CLIP chains) is fixed. | ||
|
|
||
| **Replace old nodes and custom nodes with core nodes when core can do the job.** Build it simpler and more robust than the author did when you can; read the source to know what the node does, but the core build need not be proven equivalent. Why: remove custom nodes as far as possible. | ||
| **Replace old nodes and custom nodes with core nodes only when core does the same thing the same way.** The same way: the same calculation. What may differ: settings that do not change the kind of what comes out (weight dtype, quality, encoding), the image size when it still fits the model's required multiple, and the file of the same model at the same size (a GGUF LLM to core's Generate Text; a newer version of the same model that core reads). A model of another size (27B to 9B) is another model: keep the node, and suggest the core way in a Caution Note. A core node made as core's form of that custom node's feature counts as the same way, even when some of its methods or its sampler differ (Transfer Color for KJNodes' Color Match, core's SUPIR patch for SUPIR, core's tiles for Ultimate SD Upscale: the seams blend differently and the size may differ by a few pixels); write what changes in the report. The core build may be a few core nodes making the same calculation; read the source to know what the node does. Why: remove custom nodes as far as possible, without changing what the workflow makes. | ||
| - Look up replacements.md first and follow it exactly. Otherwise read the node's source (how to find it: top of replacements.md), write it in the understanding document's table, and rewire if copying values is not enough. A deprecated node goes to its successor. Readable forms of the same calculation are in techniques.md. | ||
| - Keep it when: the part core cannot do changes the shape of the output (image size, number of images or frames, length); it is a GGUF loader; it is a special sampler (ClownsharKSampler and the like); replacing it would take away an operation the user does by dragging on screen; core cannot take the same input by wire (a crop whose region comes in by wire); its source cannot be found. Report what was kept and why. | ||
| - Use core when only internal numbers change (weights, quality, encoding), when the image size changes but still fits the model's required multiple, or when only the model file changes and core has the function (a GGUF LLM to core's Generate Text). Prefer core nodes not marked `experimental`. | ||
| - Bad: a custom node kept although none of the reasons to keep it applies. A custom node kept without reading what it does with its values here. | ||
| - A different way is not the same thing, even when the core node does the job better (TeaCache and core's EasyCache speed up differently; MiDaS and core's Depth Anything 3 make different depth maps): keep the custom node, and suggest the core way in a Caution Note (notes.md). | ||
| - A node that only makes the run faster (a cache), left with nothing to attach to because the custom nodes it was attached to are replaced by core: its core counterpart is put in its place, bypassed, and the Caution Note says the speed-up works another way and how to turn it on. | ||
| - Keep it also when: it is a GGUF loader; it is a special sampler (ClownsharKSampler and the like); replacing it would take away an operation the user does by dragging on screen; core cannot take the same input by wire (a crop whose region comes in by wire); its source cannot be found (what it does cannot be told). | ||
| - Bad: a custom node kept although core does the same thing the same way and none of the reasons to keep it applies. A custom node replaced by a core node that does the job another way. A custom node kept without reading what it does with its values here. | ||
|
|
||
| **Remove what reaches no output or does nothing with its values, and report it**: pass-through nodes; a LoRA at strength 0; a text processor whose features the text does not use; resizing to its own size; resizes one after another (merge them); a save node chosen for a feature it does not use (saving with metadata when no metadata is used: core Save Image already writes the workflow into the image); nodes that do not change the result (playing a sound, freeing GPU memory); a Preview only for looking (an image that was only resized). | ||
| **Remove what does nothing with its values**: pass-through nodes; a LoRA at strength 0; a text processor whose features the text does not use; resizing to its own size; resizes one after another (merge them); a save node chosen for a feature it does not use; nodes that do not change the result (playing a sound, freeing GPU memory); a Preview only for looking (an image that was only resized). | ||
| - Fine: a Preview that lets the user check something the result depends on (which person in the input video the reference image goes on). A Compare the author added (it stays; where it stands: readable-form.md). A step that does nothing but makes the flow clearer (a size match before a compare). | ||
| - Bad: any of the above left in the rebuilt workflow. | ||
|
|
||
| **A save node that only writes generation data into the image becomes core Save Image.** Why: core Save Image already writes the prompt and the workflow into the image; the extra data changes nothing in the result, and the values wired to it (seed, steps, cfg, sampler, size, model names) run across the whole workflow. | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| - Before: a metadata saver taking seed, steps, cfg, sampler and model names from value nodes, seven wires across the workflow to reach it. After: core Save Image on the image; the value nodes feed only the nodes that use them. | ||
| - Fine: a save node that writes something besides the image that the workflow is for (a caption text file next to each image for a dataset). It is part of what the workflow makes. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Script executed:
Repository: nomadoor/comfyui-readable-node
Length of output: 33914
Web query:
ComfyUI official VAE Decode Tiled documentation memory reduce compared VAE Decode tiled GPU out of memoryResult:
Web query:
site:github.com/Comfy-Org/ComfyUI "def decode(self, samples_in)" "tiled" "out of memory" VAEResult:
Script executed:
Repository: nomadoor/comfyui-readable-node
Length of output: 45927
Web query:
ComfyUI v0.39.0 comfy sd.py decode tiled fallback decode_tiled_ tile_x 64 out of memory VAEResult:
Web query:
ComfyUI tiled VAE decode smaller tile size out of memory automatic fallback default tile sizeResult:
Script executed:
Repository: nomadoor/comfyui-readable-node
Length of output: 15131
Preserve the selectable tiled decoder.
If the original uses a smaller tile size, removing that decoder can make the rebuilt workflow run out of memory. The ordinary decoder retries with fixed-size tiles, which may also be too large. Keep the tiled path and its settings when both decoders are selectable.