Averaging

Routines for averaging visibility data.

Numpy

time_and_channel(time, ant1, ant2, vis, flags) Average visibility data over time and channel.
africanus.averaging.time_and_channel(time, ant1, ant2, vis, flags, avg_time=None, avg_chan=None, return_time=False, return_antenna=False)[source]

Average visibility data over time and channel.

Parameters:
time : numpy.ndarray

time data of shape (row,).

antenna1 : numpy.ndarray

antenna1 of shape (row,).

antenna2 : numpy.ndarray

antenna2 of shape (row,).

vis : numpy.ndarray

visibility data of shape (row, chan, corr).

flags : numpy.ndarray

flags of shape (row, chan, corr).

avg_time : None or int, optional

Number of times to average into each time bin. Defaults to None, in which case no averaging is performed.

avg_chan : None or int, optional

Number of channels to average into each channel bin. Defaults to None, in which case no averaging is performed.

return_time : {True, False}

Return time centroids of averaged visibilities. Defaults to False.

return_antenna : {True, False}

Return antenna pairs (baseline) of averaged visibilities. Defaults to False.

Returns:
averaged_visibilities : numpy.ndarray

Averaged visibilities of shape (row, chan, corr)

averaged_time : numpy.ndarray, optional

Averaged time centroids of shape (row,)

averaged_antenna1 : numpy.ndarray, optional

antenna1 of averaged visibilities of shape (row,)

averaged_antenna2 : numpy.ndarray, optional

antenna2 of averaged visibilities of shape (row,)

Dask

time_and_channel(time, ant1, ant2, vis, flags) Average visibility data over time and channel.
africanus.averaging.dask.time_and_channel(time, ant1, ant2, vis, flags, avg_time=None, avg_chan=None, return_time=False, return_antenna=False)[source]

Average visibility data over time and channel.

Parameters:
time : dask.array.Array

time data of shape (row,).

antenna1 : dask.array.Array

antenna1 of shape (row,).

antenna2 : dask.array.Array

antenna2 of shape (row,).

vis : dask.array.Array

visibility data of shape (row, chan, corr).

flags : dask.array.Array

flags of shape (row, chan, corr).

avg_time : None or int, optional

Number of times to average into each time bin. Defaults to None, in which case no averaging is performed.

avg_chan : None or int, optional

Number of channels to average into each channel bin. Defaults to None, in which case no averaging is performed.

return_time : {True, False}

Return time centroids of averaged visibilities. Defaults to False.

return_antenna : {True, False}

Return antenna pairs (baseline) of averaged visibilities. Defaults to False.

Returns:
averaged_visibilities : dask.array.Array

Averaged visibilities of shape (row, chan, corr)

averaged_time : dask.array.Array, optional

Averaged time centroids of shape (row,)

averaged_antenna1 : dask.array.Array, optional

antenna1 of averaged visibilities of shape (row,)

averaged_antenna2 : dask.array.Array, optional

antenna2 of averaged visibilities of shape (row,)