resize_array

resize_array#

stimupy.utils.resize_array(arr, factor)#

Return a copy of an array, resized by the given factor. Every value is repeated factor[d] times along dimension d.

Parameters:
  • arr (2D array) – the array to be resized

  • factor (tuple of 2 ints) – the resize factor in the y and x dimensions

Return type:

An array of shape (arr.shape[0] * factor[0], arr.shape[1] * factor[1])