Voronoi tessellation based cluster analysis?

Hello PYMErs,

Does PYME offer Voronoi tessellation based cluster analysis? If so, how does one use it? I’m interested in identifying and visualizing clusters using this method.

Thank you,
Lukas

Hi @lukasfue,

Voronoi tessellation and Delaunay triangulation are very closely related. One of the ways I like to do parameter-free cluster segmentation is to do a density mapping using jittered triangulation (Delaunay) with intensities weighted on neighbourDistances and then apply an automated threshold like otsu to the resulting image, label it, and map back to the localizations.

My remote desktop is down at the moment so I haven’t tested this, but should look something like

recipe text
- localisations.AddPipelineDerivedVars:
    inputEvents: ''
    inputFitResults: FitResults
    outputLocalizations: Localizations
- localisations.ProcessColour:
    input: Localizations
    output: colour_mapped
- tablefilters.FilterTable:
    filters:
      A:
      - 5
      - 20000
      error_x:
      - 0
      - 30
      error_y:
      - 0
      - 30
    inputName: colour_mapped
    outputName: filtered_localizations
- localisations.DensityMapping:
    colours:
    - chan0
    inputLocalizations: filtered_localizations
    jitterVariable: neighbourDistances
    jitterVariableZ: neighbourDistances
    outputImage: jt3d
    pixelSize: 25.0
    renderingModule: 3D Triangularisation
    zBoundsMode: min-max
- processing.Threshold:
    inputName: jt3d
    method: otsu
    outputName: otsu
    processFramesIndividually: false
- processing.Label:
    inputName: otsu
    outputName: labeled
    processFramesIndividually: false
- localisations.LabelsFromImage:
    inputImage: labeled
    inputName: filtered_localizations
    outputName: labeled_points

Is there a chance that might work for your use case?