def get_matches(lf, candidate_set, match_values=[<NUM_LIT:1>, -<NUM_LIT:1>]):
logger = logging.getLogger(__name__)<EOL>matches = []<EOL>for c in candidate_set:<EOL><INDENT>label = lf(c)<EOL>if label in match_values:<EOL><INDENT>matches.append(c)<EOL><DEDENT><DEDENT>logger.info(f"<STR_LIT>")<EOL>return matches<EOL>
Return a list of candidates that are matched by a particular LF.

    A simple helper function to see how many matches (non-zero by default) an
    LF gets.

    :param lf: The labeling function to apply to the candidate_set
    :param candidate_set: The set of candidates to evaluate
    :param match_values: An option list of the values to consider as matched.
        [1, -1] by default.
    :rtype: a list of candidates