paste#
- arte.utils.paste.paste(wall, block, loc)#
Paste
blockarray intowallin locationloc.locmust be a tuple (even if block.ndim=1) Going outside of the edges ofwallis properly managed.wallis modified in place.- Parameters:
- Return type:
None
Example
Insert array [1,2,3,4] into an empty array of size 10 at location 8
>>> b = np.zeros([10]) >>> a = np.arange(1, 5) >>> b array([ 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.]) >>> a array([1, 2, 3, 4]) >>> paste(b, a, (8,)) >>> b array([ 0., 0., 0., 0., 0., 0., 0., 0., 1., 2.])
References