matplotlib 3.5.1

ParametersBackRef
resample(input_array, output_array, matrix, interpolation=NEAREST, alpha=1.0, norm=False, radius=1)

Parameters

input_array : 2-d or 3-d Numpy array of float, double or uint8

If 2-d, the image is grayscale. If 3-d, the image must be of size 4 in the last dimension and represents RGBA data.

output_array : 2-d or 3-d Numpy array of float, double or uint8

The dtype and number of dimensions must match :None:None:`input_array`.

transform : matplotlib.transforms.Transform instance

The transformation from the input array to the output array.

interpolation : int, optional

The interpolation method. Must be one of the following constants defined in this module:

NEAREST (default), BILINEAR, BICUBIC, SPLINE16, SPLINE36, HANNING, HAMMING, HERMITE, KAISER, QUADRIC, CATROM, GAUSSIAN, BESSEL, MITCHELL, SINC, LANCZOS, BLACKMAN

resample : bool, optional

When :None:None:`True`, use a full resampling method. When :None:None:`False`, only resample when the output image is larger than the input image.

alpha : float, optional

The level of transparency to apply. 1.0 is completely opaque. 0.0 is completely transparent.

norm : bool, optional

Whether to norm the interpolation function. Default is :None:None:`False`.

radius: float, optional :

The radius of the kernel, if method is SINC, LANCZOS or BLACKMAN. Default is 1.

Resample input_array, blending it in-place into output_array, using an affine transformation.

Examples

See :

Back References

The following pages refer to to this document either explicitly or contain code examples using this.

matplotlib.image._resample

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


File: None#None
type: <class 'builtin_function_or_method'>
Commit: