average_chunks2

ska_sdp_func_python.util.array_functions.average_chunks2(arr, wts, chunksize)[source]

Average the two-dimensional array arr with weights by chunks.

Array length does not have to be multiple of chunksize.

Parameters:
  • arr – 2D array of values

  • wts – 2D array of weights

  • chunksize – 2-tuple of averaging region e.g. (2,3)

Returns:

2D array of averaged data_models, 2d array of weights