Select Masks π₯π ₯π π ’
VHS_SelectMasksUse comma-separated indexes to select items in the given order. Supports negative indexes, python-style ranges (end index excluded), as well as range step. Acceptable entries (assuming 16 items provided, so idxs 0 to 15 exist): 0 -> Returns [0] -1 -> Returns [15] 0, 1, 13 -> Returns [0, 1, 13] 0:5, 13 -> Returns [0, 1, 2, 3, 4, 13] 0:-1 -> Returns [0, 1, 2, ..., 13, 14] 0:5:-1 -> Returns [4, 3, 2, 1, 0] 0:5:2 -> Returns [0, 2, 4] ::-1 -> Returns [15, 14, 13, ..., 2, 1, 0]
Example
{
"class_type": "VHS_SelectMasks",
"inputs": {
"mask": [
"node_id",
0
],
"indexes": "0",
"err_if_missing": true,
"err_if_empty": true
}
}This example shows required inputs only. Connection values like ["node_id", 0] should reference actual node IDs from your workflow.
Inputs
| Name | Type | Status | Constraints | Default |
|---|---|---|---|---|
mask | MASK | required | - | - |
indexes | STRING | required | - | "0" |
err_if_missing | BOOLEAN | required | - | true |
err_if_empty | BOOLEAN | required | - | true |
Outputs
| Index | Name | Type | Is List | Connection Reference |
|---|---|---|---|---|
0 | MASK | MASK | No | ["{node_id}", 0] |
How to connect to these outputs
To connect another node's input to an output from this node, use the connection reference format:
["node_id", output_index]Where node_id is the ID of this VHS_SelectMasks node in your workflow, and output_index is the index from the table above.
Example
If this node has ID "5" in your workflow:
MASK (MASK):["5", 0]