def age_window_hit(by_predicted, by_truth, m=lambda x: -0.1*x+202.8):
    """
    calculates the window for a given truth and checks if the prediction lies within that window
    :param by_predicted: the predicted birth year
    :param by_truth: the true birth year
    :param m: function giving the window size when given by_truth.
    :return: true if by_predicted within m-window of by_truth
    """
    return int(by_truth - m(by_truth)) <= by_predicted <= int(by_truth + m(by_truth))