Link Search Menu Expand Document

Find Clusters

PCGEx | Find Clusters

Find matching cluster data.

The Find Clusters node locates matching Vtx and Edges pairs from disordered data collections, helping streamline operations when working with individual clusters.


Vtx
Endpoints of the input Edges
Edges
Edges associated with the input Vtxs
Vtx or Edges
Key data to be matched against. Availability depends on the selected Search Mode.
Vtx
Endpoints of the output Edges
Edges
Edges associated with the output Vtxs

Table of content


The Find Clusters node is a handy helper to find matching Vtx and Edges data from more-or-less scrambled collections of data. It basically makes it easy to do non-destructive operations (i.e attribute ops) on both Vtx & Edges at the same time without and then “restore” the working pairs.
Alternatively, it also makes it easy to cherry pick Vtx or Edges if you have single key data to restore from. (i.e loop subgraphs)

Note that this node is not an alternative to Sanitize Clusters, it only works at the collection level and doesn’t inspect per-point data.

details/clusters-find-cluster-data/lead.png

Properties


Property Description
Search Mode Defines how to search and what the node will output.
Some search modes will unlock additional inputs.
Skip Trivial Warnings If enabled, will skip trivial warnings about unmatched pairs and missing siblings.
Skip Important Warnings If enabled, will skip important warnings that you may get from incomplete data.

The ability to skip warning is there mostly because I found this node to be often purposefully used with “bad” data, and you don’t want to be spammed with infos you already know. Just don’t forget to uncheck these if for some reason the node is not generating the output you’d expect; it will definitely provide some details on why.

Search modes

details/clusters-find-cluster-data/alt.png

All

This search mode finds all valid Vtx & Edges pair and output the workable ones.
If a Vtx is found but no matching Edges are, or vice versa (Edges found but no assocated Vtx), They will be ommited from the ouput.

Vtx from Edges

This search modes finds the single valid Vtx associated with the Edges found in the corresponding node input.
If none is found, the entire output will be empty.

Edges from Vtx

This search modes finds all valid Edges associated with the Vtx found in the corresponding node input.
If none is found, the entire output will be empty.


Usage in loops

Looping over individual clusters can look like a needlessly complex task: how do you get the right Edges with the right Vtx or vice versa? Well, this node is there to help!

In order to loop over individual clusters, you need to loop over the Edges dataset, not the Vtx; because Vtx dataset may be bound to more than one Edges set. Check out Working with Clusters for more infos on that.
Forward Vtx groups to another loop input and use the Vtx from Edges input, like so:

details/clusters-find-cluster-data/loop.png