def filter_labels_by_occlusion(obj_labels, occlusion):
    """Filters object labels by truncation.

    Args:
        obj_labels: List of object labels
        occlusion: Maximum occlusion

    Returns:
        obj_labels: List of filtered labels
        occ_mask: Mask of labels to keep
    """
    occ_mask = [obj_label.occlusion < occlusion
                for obj_label in obj_labels]

    return obj_labels[occ_mask], occ_mask