def rate_black_pixel_ratio (
        ratio: int,
        thres_1: int = 20,
        thres_2: int = 50
    ) -> int:
    """ Evaluates the given black-pixel-ratio and returns the detected marking.

    Args:
        ratio (int):
            the ratio of black pixels compared to total pixels
        thres_1 (int):
            threshold for checked boxes
        thres_2 (int):
            threshold for corrected boxes

    Returns:
        -1 if a box is filled
        1 if a box is checked
        0 if a box is empty
    """
    if ratio >= thres_2:
        return -1 # corrected box
    if ratio >= thres_1:
        return 1 # checked
    else: # empty box
        return 0