def translate_bbox(bbox, translation):
    """
    Translate given bbox by the amount in translation.

    Parameters
    ----------
    bbox: tuple
          tuple of integers defining coordinates of the form
          (x1, y1, x2, y2, x3, y3, x4, y4).
    translation: tuple
                 tuple of integers defining the translation to apply on
                 the x axis (translation[0]) and the y axis (translation[1]).
    """
    new_bbox = (bbox[0] + translation[0],
                bbox[1] + translation[1],
                bbox[2] + translation[0],
                bbox[3] + translation[1],
                bbox[4] + translation[0],
                bbox[5] + translation[1],
                bbox[6] + translation[0],
                bbox[7] + translation[1])
    return new_bbox