Python module to handle the channelization and cross-correlation of TBW and TBN data. The main python functions in this module are:
- calcSpectra - calculate power spectra for a collection of signals
- FXCorrelator - calculate cross power spectra for a collection of signals
- FXStokes - calculate Stokes cross power spectra for a collection of signals
both of which have been deprecated in favor of the new C extension based routines listed below.
Each function is set up to process the signals in parallel using the multiprocessing module and accepts a variety of options controlling the processing of the data, including various window functions and time averaging.
Changed in version 1.0.1: Removed SpecMasterP.
Changed in version 1.0.0: All of the functions here now return all ‘LFFT’ channels.
Generate a list of two-element tuples that describe which antennae compose each of the output uvw triplets from computeUVW/computeUVTrack. If the Indicies keyword is set to True, the two-element tuples contain the indicies of the stands array used, rather than the actual stand numbers.
Given a baseline number, a list of stands, and options of how the base- line listed was generated, convert the baseline number to antenna numbers. Alternatively, use a list of baselines instead of generating a new list. This utility is useful for figuring out what antennae comprise a baseline.
Given two antenna numbers, a list of stands, and options to how the base- line listed was generated, convert the antenna pair to a baseline number. This utility is useful for picking out a particular pair from a list of baselines.
Compute the uvw converate of a baselines formed by a collection of stands. The coverage is computed at a given HA (in hours) and declination (in degrees) for a given site. The frequency provided (in Hz) can either as a scalar or as a numpy array. If more than one frequency is given, the output is a three dimensional with dimensions of baselines, uvw, and frequencies.
Changed in version 0.4.0: Switched over to passing in Antenna instances generated by the lsl.common.station module instead of a list of stand ID numbers.
Changed in version 1.0.0: Added a keyword (site) to specify the station used for the observation.
Changed in version 1.1.2: Updated to work with lists in a transparent manner.
Whereas computeUVW provides the uvw coverage at a particular time, computeUVTrack provides the complete uv plane track for a long integration. The output is a three dimensional numpy array with dimensions baselines, uv, and 512 points along the track ellipses. Unlike computeUVW, however, only a single frequency (in Hz) can be specified.
Changed in version 0.4.0: Switched over to passing in Antenna instances generated by the lsl.common.station module instead of a list of stand ID numbers.
Changed in version 1.0.0: Added a keyword (site) to specify the station used for the observation.
This module implements a uniform DFT filter bank for use in calculating spectra as an alternative to a simple FFT. The implementation here is based on: http://www.scribd.com/doc/20561850/6/Polyphase-Filter-Coef%EF%AC%81cients
Changed in version 1.0.1: Added support for using PyFFTW instead of NumPy for the FFTs
FFT-based poly-phase filter bank for creating N channels with P taps. Optionally, a window function can be specified using the ‘window’ keyword. See lsl.correlator.fx.calcSpectra for details on using window functions.
Sub-type of lsl.correlator.filterbank.fft that uses two taps.
Sub-type of lsl.correlator.filterbank.fft that uses four taps.
Sub-type of lsl.correlator.filterbank.fft that uses eight taps.
Sub-type of lsl.correlator.filterbank.fft that uses 16 taps.
Sub-type of lsl.correlator.filterbank.fft that uses 32 taps.
Default “empty” windowing function for use with the various routines. This function returned a numpy array of ‘1’s of the specified length.
A more advanced version of FXCorrelator for TBW and TBN data. Given an 2-D array of signals (stands, time-series) and an array of stands, compute the cross-correlation of the data for all baselines. Return the frequencies and visibilities as a two-elements tuple.
Changed in version 0.4.0: Switched over to passing in Antenna instances generated by the lsl.common.stations module instead of a list of stand ID numbers.
Changed in version 1.0.0: Added a phase-center keyword that accept a two-element tuple of azimuth and elelvation (in degrees) to change where the correlations are phased to
Changed in version 1.1.0: Made the ‘phaseCenter’ keyword more flexible. It can now be either: * ‘z’ to denote the zenith, * a ephem.Body instances which has been computed for the observer, or * a two-element tuple of azimuth, elevation in degrees.
A more advanced version of FXCorrelator for TBW and TBN data. Given an 2-D array of signals (stands, time-series) and an array of stands, compute the cross-correlation of the data for all baselines. Return the frequencies and visibilities as a two-elements tuple.
Changed in version 1.0.0: Added a phase-center keyword that accept a two-element tuple of azimuth and elelvation (in degrees) to change where the correlations are phased to
Changed in version 1.1.0: Made the ‘phaseCenter’ keyword more flexible. It can now be either: * ‘z’ to denote the zenith, * a ephem.Body instances which has been computed for the observer, or * a two-element tuple of azimuth, elevation in degrees.