flitsr.advanced.parallel.Parallel

class flitsr.advanced.parallel.Parallel(parType: str = 'msp')

Bases: Cluster

Run one of the parallel debugging algorithms on the spectrum to produce multiple spectrums, and process all other options on each spectrum.

__init__(parType: str = 'msp')

Constructs a Parallel Cluster object. Takes a partition type parType, which is the algorithm to run. The choices are: ‘bdm’, ‘msp’, ‘hwk’, and ‘vwk’.

Methods

__init__([parType])

Constructs a Parallel Cluster object.

cluster(inp_file, spectrum[, method_lvl])

Run one of the Parallel clustering algorithms over the given spectrum.

partition_table(d, spectrum)

Partitions the given spectrum using one of the parallel algorithms into multiple decomposed spectra.

trim_groups(spectrum)

Remove groups in the spectrum in place that are not in this block (i.e. ef = 0).

cluster(inp_file: str, spectrum: Spectrum, method_lvl=False) List[Spectrum]

Run one of the Parallel clustering algorithms over the given spectrum.

Parameters:
  • inp_file – str: The file path of the input file containing the spectrum.

  • spectrum – Spectrum: The input spectrum.

  • method_lvl – (Default value = False) Whether the input spectrum is method level.

Returns:

A collection of subspectra formed by decomposing the input spectrum.

partition_table(d: str, spectrum: Spectrum) List[Spectrum]

Partitions the given spectrum using one of the parallel algorithms into multiple decomposed spectra.

Parameters:
  • d – str: The location path for the input file containing the spectrum.

  • spectrum – Spectrum: The input spectrum.

Returns:

A collection of spectra which are decompositions of the input spectrum.

trim_groups(spectrum)

Remove groups in the spectrum in place that are not in this block (i.e. ef = 0).

Parameters:

spectrum – The spectrum for which to trim the groups.