class xpipeline.core.xtimefrequencymap.csc_XSparseTimeFrequencyMap(matrix, **kwargs)[source]

Bases: xpipeline.core.sparse.csc_sparse_map

cluster(self, method='nearest_neighbors', **kwargs)[source]

Convert dict fo sparse matrix to XTimeFrequencyMapDict

label(self, connectivity=8)[source]

Convert dict fo sparse matrix to XTimeFrequencyMapDict

plot(self, **kwargs)[source]

Plot the data for this XTimeFrequencyMapDict.

Parameters

**kwargs

all other keyword arguments are passed to the plotter as appropriate

classmethod read(row)[source]

This can table a row of a PyTable and return a sparse tf map.

Parameters

row (`tables.Table.row`):

The is a row of a tables.Table generated by xpipeline-analysis

**kwargs

all other keyword arguments are passed to the plotter as appropriate

write(self, filename, path, table_description=None, **kwargs)[source]

Plot the data for this XTimeFrequencyMapDict.

Parameters

**kwargs

all other keyword arguments are passed to the plotter as appropriate

xpipeline.core.xtimefrequencymap.residual_time_shift(seconds, frequencies)[source]
class xpipeline.core.xtimefrequencymap.XTimeFrequencyMap[source]

Bases: gwpy.spectrogram.spectrogram.Spectrogram

blackout_pixels(self, blackpixel_percentile, **kwargs)[source]

Set pixels below certain energy level to zero

Parameters:

blackpixel_percentileint

the x-percentile loudest tile all pixels below which will be set to energy of 0

gaussianity(self)[source]

Calculate the gaussianity of this map

(.abs().percentile(99)/ .abs().median(0))**2 Returns:

gwpy.frequency.FrequencySeries:

The gaussianity measure of each frequency bin

phaseshift(self, delta)[source]

Phase shift this spectrogram by delta

This modifies the spectrogram in-place.

Parameters

delta : float, ~astropy.units.Quantity, str

The amount by which to shift (in seconds if float), give a negative value to shift backwards in time

to_dominant_polarization_frame(self, dpf_asd)[source]
to_sparse(self, tindex, findex, **kwargs)[source]

Parameters:

tindexarray,

an array of the time indices to extract for the creation of a dict of sparse tfmaps from a dict of full tfmaps

findexdict,

an array of the frequency indices to extract for the creation of a dict of sparse tfmaps from a dict of full tfmaps

Returns:
XSparseTimeFrequencyMapDict:

Sparse matrices using supplied t-f indices and extracting the data at those points from the full tfmap.