mmcv/image/transforms/resize.py
def imresize_like(img, dst_img, return_scale=False, interpolation='bilinear'):
    """Resize image to the same size of a given image.

    Args:
        img (ndarray): The input image.
        dst_img (ndarray): The target image.
        return_scale (bool): Whether to return `w_scale` and `h_scale`.
        interpolation (str): Same as :func:`resize`.

    Returns:
        tuple or ndarray: (`resized_img`, `w_scale`, `h_scale`) or
            `resized_img`.
    """
    h, w = dst_img.shape[:2]
    return imresize(img, (w, h), return_scale, interpolation)
def imresize_like(img, dst_img, return_scale=False, interpolation='bilinear'):
    h, w = dst_img.shape[:2]
    return imresize(img, (w, h), return_scale, interpolation)
def imresize_like ( img , dst_img , return_scale = False , interpolation = 'bilinear' ) : h , w = dst_img . shape [ : 2 ] return imresize ( img , ( w , h ) , return_scale , interpolation )
Resize image to the same size of a given image.

    Args:
        img (ndarray): The input image.
        dst_img (ndarray): The target image.
        return_scale (bool): Whether to return `w_scale` and `h_scale`.
        interpolation (str): Same as :func:`resize`.

    Returns:
        tuple or ndarray: (`resized_img`, `w_scale`, `h_scale`) or
            `resized_img`.
Resize image to the same size of a given image .