def scaleImg(width, height, img, keepRatio=False):
    """Scale image to given width and height if keep aspect ratio is True
    """
    ignoreAspectMark = '!' if keepRatio is False else ''
    transformStr = '{}{}x{}'.format(ignoreAspectMark, width, height)
    print('Scale to {}'.format(transformStr))
    img.transform(transformStr)
    return img
