Timeseries Testing and Modeling

Jorge III Altamirano-Astorga, Ita-Andehui Santiago, Luz Aurora Hernández.

Prof.: Edgar Francisco Román-Rangel.

Timeseries

We use the the timeseries_dataset_from_array function from Keras Timeseries modeling functions. This function creates dataframes with sliding windows over time as an array.

This function work as follow:

tf.keras.utils.timeseries_dataset_from_array(
    X, Y,              # our dataset
    sequence_length,   #  Length of the output sequences (in number of timesteps): we need to text different sliding lengths to see how to get the best results on Deep Learning and not extending the processing time too much
    sequence_stride=1, # 1 is the default value for s, data[i], data[i + s], data[i + 2 * s]
    sampling_rate=1,   # 1 is the default value for timesteps data[i], data[i + r], ... data[i + sequence_length]
    shuffle=False,     # shuffle the records sorting, we set it in the default false value as the original order is relevant for timeseries 
    seed=None,         # we set a fixed seed to have repeatable experiments
    #...
)

On our research it is relevant to have an adequate sequence length. Then we can focus a brief research on empiric good times. Our proposal are:

1 Minute Resampling

2 Minute Resampling

5 Minute Resampling

We set this the number of days in a variable we set as WINDOW_SIZE_DAYS

5 Minute Resampling and 7 Days of History.

5 Minute Resampling and 2 Days of History with 2 Sampling Rate.

On our previous examples this quickly becomes unmanageable the we propose skipping some records and getting the previous hour by setting the sampling_rate parameter of 10 minute.

Model DNN01

Model Best 03a

Model Best 03b

Model RNN00

Model RNN02

Model LSTM00

Model LSTM02

Model Conv00

Model Conv02

Model DNN00

Model DNN02

Model Baseline

Fixing 6 Weeks Models

We found that the validation didn't run for some reason on our models when having a history of 6 weeks.

Reading the models:

We set the data source in order to get the:

We proceed to get the predict the $\hat{y}$:

Model ParNet0

Downsampling

SSE

Stream

Sequence

Job Training