Skip to content

@graphty/algorithms / index / SyncClusteringResult

Interface: SyncClusteringResult ​

Defined in: indexed/sync.ts:33

Result of the index-based SynC clustering.

Properties ​

converged ​

readonly converged: boolean

Defined in: indexed/sync.ts:58

Whether the run stopped before the cap: the cluster assignment stayed the same for 10 iterations in a row, or the loss settled within the tolerance.


count ​

readonly count: number

Defined in: indexed/sync.ts:37

Number of cluster centres: numClusters.


dimensions ​

readonly dimensions: number

Defined in: indexed/sync.ts:47

Embedding length: min(64, nodeCount).


embeddings ​

readonly embeddings: F64

Defined in: indexed/sync.ts:45

Node embeddings, row-major: node i is embeddings.subarray(i * dimensions, (i + 1) * dimensions).


iterations ​

readonly iterations: number

Defined in: indexed/sync.ts:53

Iterations run.


labels ​

readonly labels: U32

Defined in: indexed/sync.ts:35

The centre each node is closest to, in [0, count). A centre may end up with no node.


loss ​

readonly loss: number

Defined in: indexed/sync.ts:49

Loss of the last iteration run (Infinity when none ran).


previousLoss ​

readonly previousLoss: number

Defined in: indexed/sync.ts:51

Loss of the iteration before the last (Infinity when fewer than two ran).

Methods ​

groups() ​

groups(): U32[]

Defined in: indexed/sync.ts:43

Node indices grouped by centre, count arrays (an empty one for a centre no node is closest to), computed once and cached.

Returns ​

U32[]

One array per centre