SpectralCloudstering

class scimes.SpectralCloudstering(dendrogram, catalog, cl_volume=True, cl_luminosity=True, user_k=None, user_ams=None, user_scalpars=None, savesingles=False, locscaling=False, blind=False)[source] [edit on github]

Bases: object

Apply the spectral clustering to find the best cloud segmentation out from a dendrogram.

Parameters:

dendrogram: ‘astrodendro.dendrogram.Dendrogram’ instance

The dendrogram to clusterize

catalog: ‘astropy.table.table.Table’ instance

A catalog containing all properties of the dendrogram structures. Generally generated with ppv_catalog module

cl_volume: bool

Clusterize the dendrogram using the ‘volume’ criterium

cl_luminosity: bool

Clusterize the dendrogram using the ‘luminosity’ criterium

user_k: int

The expected number of clusters, if not provided it will be guessed automatically through the eigenvalues of the unsmoothed affinity matrix

user_ams: numpy array

User provided affinity matrix. Whether this is not furnish it is automatically generated through the volume and/or luminosity criteria

user_scalpars: list of floats

User-provided scaling parameters to smooth the affinity matrices

locscaling: bool

Smooth the affinity matrices using a local scaling technique

savesingles: bool

Consider the single, isolated leaves as individual ‘clusters’. Useful for low resolution data where the beam size corresponds to the size of a Giant Molecular Cloud.

blind: bool

Show the affinity matrices. Matplotlib required.

Methods Summary

Methods Documentation

asgncube(header, collapse=True)[source] [edit on github]

Create a label cube with only the cluster (cloudster) IDs included, and write to disk.

Parameters:

header : fits.Header

The header of the output assignment cube. Should be the same header that the dendrogram was generated from

collapse : bool

Collapsed (2D) version of the assignment cube

plot_connected_clusters(**kwargs)[source] [edit on github]
showdendro()[source] [edit on github]

Show the clustered dendrogram every color correspond to a different cluster