cupy.append#
- cupy.append(arr, values, axis=None)[source]#
Append values to the end of an array.
- Parameters:
arr (array_like) – Values are appended to a copy of this array.
values (array_like) – These values are appended to a copy of
arr
. It must be of the correct shape (the same shape asarr
, excludingaxis
). Ifaxis
is not specified,values
can be any shape and will be flattened before use.axis (int or None) – The axis along which
values
are appended. Ifaxis
is not given, botharr
andvalues
are flattened before use.
- Returns:
A copy of
arr
withvalues
appended toaxis
. Note thatappend
does not occur in-place: a new array is allocated and filled. Ifaxis
is None,out
is a flattened array.- Return type:
See also