def _seconds_to_section_split(record, sections):
    """
    Finds the seconds to the next section from the datetime of a record.
    """

    next_section = sections[
        bisect_right(sections, _find_weektime(record.datetime))] * 60
    return next_section - _find_weektime(record.datetime, time_type='sec')
dataset/ETHPy150Open yvesalexandre/bandicoot/bandicoot/special/punchcard.py/_seconds_to_section_split/original