Create time intervals with timedelta periods using datetime for start
    and end

def gen_time_intervals(start, end, delta):
    """Create time intervals with timedelta periods using datetime for start
    and end
    """
    curr = start
    while curr < end:
        yield curr
        curr += delta