def lin_anneal(step, total, ceiling=0.5):
    """ Linear annealing function
    :param step:
    :param total:
    :param ceiling: Where in the process the aneal should hit 1. If 0.5, the anneal linearly climbs upt to 1 and then
        hits 1 halfway
    :return:
    """
    return min(1, (step/ceiling) / total)