katcbf_vlbi_resample.resample module
Signal processing algorithms.
- class katcbf_vlbi_resample.resample.ClipTime(input_data: Stream[DataArray], start: Time | int | None = None, stop: Time | int | None = None)
Bases:
objectIterator adapter that limits the selected time range.
Note that it’s generally more efficient if the upstream iterator can do the work. However, this adapter is convenient for clipping to sample accuracy after the upstream clips to chunk accuracy.
The range to select is based on sample indices, as given by the time_bias attribute on chunks. Alternatively, one can select by absolute time by passing instances of
astropy.time.Time.
- class katcbf_vlbi_resample.resample.IFFT(input_data: Stream[DataArray])
Bases:
ChunkwiseStream[DataArray,DataArray]Iterator adapter that converts frequency domain to time domain.
- class katcbf_vlbi_resample.resample.Resample(output_bandwidth: float | Fraction, mixer_frequency: float, resample_params: ResampleParameters, input_data: Stream[DataArray])
Bases:
objectResample to a different frequency and split into sidebands.
This class is used to wrap an iterator that yields input data in chunks to one that yields output data in chunks. The chunks are not one-to-one due to windowing effects.
Each input array must have a time dimension, and it must have a coordinate that contains consecutive integers. Each subsequent chunk must also follow on contiguously from the previous one. Chunks need not be the same size. Input samples are expected to be complex values.
The output has an additional sideband dimension to indicate the lower (lsb) or upper (usb) sideband. Output samples are real.
- Parameters:
output_bandwidth – The total bandwidth across both sidebands. This is also the sampling rate of each (real) sideband signal.
mixer_frequency – The centre frequency of the input stream minus the centre frequency of the output stream.
resample_params – Parameters controlling the response of the resampling filters.
input_data – The input data stream.