Convolve

class baseband_tasks.convolution.Convolve(ih, response, *, offset=0, samples_per_frame=None)[source] [edit on github]

Bases: baseband_tasks.convolution.ConvolveSamples

Convolve a time stream with a response, in the Fourier domain.

The convolution is done via multiplication in the Fourier domain, which is faster than direct convolution for all but very simple responses.

Parameters
ihtask or baseband stream reader

Input data stream, with time as the first axis.

responsendarray

Response to convolce the time stream with. If one-dimensional, assumed to apply to the sample axis of ih.

offsetint, optional

Where samples should be considered to be taken from. For the default of 0, a given sample has the same time as the convolution of the filter with all preceding samples.

samples_per_frameint, optional

Number of convolved samples which should be produced in one go. The number of input samples used will be larger to avoid wrapping. If not given, as produced by the larger of the input samples per frame minus padding or the minimum power of 2 of input samples that yields at least 75% efficiency.

See also

ConvolveSamples

convolution in the time domain (for simple responses)

baseband_tasks.fourier.fft_maker

to select the FFT package used.

Methods Summary

close()

Close task.

task(data)

Methods Documentation

close()[source] [edit on github]

Close task.

Note that this does not explicitly close the underlying source; instead, it just deletes the reference to it.

task(data)[source] [edit on github]