You are viewing an older version (2.4.3). Go to latest (2.4.4)
{ } Raw JSON

bundles / numpy 2.4.3 / numpy / lib / _arraypad_impl / _pad_simple

function

numpy.lib._arraypad_impl:_pad_simple

source: /numpy/lib/_arraypad_impl.py :87

Signature

def   _pad_simple ( array pad_width fill_value = None )

Summary

Pad array on all sides with either a single value or undefined values.

Parameters

array : ndarray

Array to grow.

pad_width : sequence of tuple[int, int]

Pad width on both sides for each dimension in arr.

fill_value : scalar, optional

If provided the padded area is filled with this value, otherwise the pad area left undefined.

Returns

padded : ndarray

The padded array with the same dtype as`array`. Its order will default to C-style if array is not F-contiguous.

original_area_slice : tuple

A tuple of slices pointing to the area of the original array.

Aliases

  • numpy.lib._arraypad_impl._pad_simple