AI: add is_ node for time embedding
This commit is contained in:
@@ -423,6 +423,7 @@ The following variables are available in `Expression`.
|
||||
| `is_attn2` | float (0/1) | `1` when current hook is `attn2`, else `0`. |
|
||||
| `is_dit` | float (0/1) | `1` when current hook is DiT block hook, else `0`. |
|
||||
| `is_unet_block` | float (0/1) | `1` when current hook is UNet block hook, else `0`. |
|
||||
| `is_time_emb` | float (0/1) | `1` when current hook is timestep embedding entry (`block_name=="time_emb"`), else `0`. |
|
||||
| `block_name` | string | Block/stage name (`input`, `middle`, `output`, `time_emb`, `model`, DiT block type, etc.). |
|
||||
| `layer_id` | float | Numeric block/layer id used by current hook context. |
|
||||
| `layer` | float | Alias of `layer_id`. |
|
||||
|
||||
@@ -149,6 +149,7 @@ class SelectiveGuiderMathNode(io.ComfyNode):
|
||||
"transformer_index": -1.0,
|
||||
"is_dit": 0.0,
|
||||
"is_unet_block": 0.0,
|
||||
"is_time_emb": 0.0,
|
||||
"is_attn1": 0.0,
|
||||
"is_attn2": 0.0,
|
||||
"block_name": "",
|
||||
@@ -331,6 +332,7 @@ class SelectiveGuiderMathNode(io.ComfyNode):
|
||||
"attn_kind": "none",
|
||||
"is_dit": 0.0,
|
||||
"is_unet_block": 1.0,
|
||||
"is_time_emb": 1.0 if stage == "time_emb" else 0.0,
|
||||
"is_attn1": 0.0,
|
||||
"is_attn2": 0.0,
|
||||
"block_name": stage,
|
||||
|
||||
Reference in New Issue
Block a user