cupy.full_like#
- cupy.full_like(a, fill_value, dtype=None, order='K', subok=None, shape=None)[source]#
Returns a full array with same shape and dtype as a given array.
This function currently does not support
subokoption.- Parameters:
a (cupy.ndarray) – Base array.
fill_value (Any) – A scalar value to fill a new array.
dtype (data-type, optional) – Data type specifier. The dtype of
ais used by default.order ({'C', 'F', 'A', or 'K'}) – Overrides the memory layout of the result.
'C'means C-order,'F'means F-order,'A'means'F'ifais Fortran contiguous,'C'otherwise.'K'means match the layout ofaas closely as possible.subok (None) – Not supported yet, must be None.
shape (int or tuple of ints) – Overrides the shape of the result. If
order='K'and the number of dimensions is unchanged, will try to keep order, otherwise,order='C'is implied.
- Returns:
An array filled with
fill_value.- Return type:
See also