def convertLatLongToPixels(mapImg, leftLongitude, rightLongitude, topLatitude, bottomLatitude, latLong):
    """Convert given lat/long coordinates into pixel X/Y coordinates given map and its borders

    Args:
        mapImg (Image): map image
        left/right/top/bottom: borders of map
        latlong (list): (lat, long)

    Returns:
        (x, y) pixel values of cooressponding pixel in image
    """
    latitude = min(max(latLong[0], bottomLatitude), topLatitude)
    longitude = min(max(latLong[1], leftLongitude), rightLongitude)

    diffLat = topLatitude - bottomLatitude
    diffLong = rightLongitude - leftLongitude

    pixelX = (longitude - leftLongitude)/diffLong*mapImg.size[0]
    pixelX = max(min(pixelX, mapImg.size[0] - 1), 0)
    pixelY = mapImg.size[1] - (latitude - bottomLatitude)/diffLat*mapImg.size[1]
    pixelY = max(min(pixelY, mapImg.size[1] - 1), 0)
    return (pixelX, pixelY)