image = cv2.resize(src, dsize, fx, fy, interpolation)
src The file path in which the input image resides.
dsize The size of the output image, which adheres to the syntax (width, height).
fx The scale factor for the X axis.
fy The scale factor for the Y axis.
interpolation The technique for adding or removing pixels during the resizing process. The default is cv2.INTER_LINEAR.
Here are the values for the
||The standard bilinear interpolation, ideal for enlarged images.|
||The nearest neighbor interpolation, which, though fast to run, creates blocky images.|
||The interpolation for the pixel area, which scales down images.|
||The bicubic interpolation with 4×4-pixel neighborhoods, which, though slow to run, generates high-quality instances.|
||The Lanczos interpolation with an 8×8-pixel neighborhood, which generates images of the highest quality but is the slowest to run.|