Utility function for generating batches of temporal data.
timeseries_generator( data, targets, length, sampling_rate = 1, stride = 1, start_index = 0, end_index = NULL, shuffle = FALSE, reverse = FALSE, batch_size = 128 )
Object containing consecutive data points (timesteps). The data should be 2D, and axis 1 is expected to be the time dimension.
Targets corresponding to timesteps in
It should have same length as
Length of the output sequences (in number of timesteps).
Period between successive individual timesteps
within sequences. For rate
data[i - length]
are used for create a sample sequence.
Period between successive output sequences.
s, consecutive output samples would
be centered around
Data points earlier than
or later than
end_index will not be used in the output sequences.
This is useful to reserve part of the data for test or validation.
Whether to shuffle output samples, or instead draw them in chronological order.
true, timesteps in each output sample will be
in reverse chronological order.
Number of timeseries samples in each batch (except maybe the last one).
An object that can be passed to generator based training