Icon

03 Training an LSTM Model

03 Training an LSTM Model - Exercise

This workflow shows a hands-on exercise in the L4-DL Introduction to Deep Learning self-paced course

Task 1: Preprocess the data1. Convert the pickup_timestamp column into Date&Time2. Sort the data by time in ascending order3. Create 24 columns for the 24 past hours' trip counts4. Create a collection column of these past values5. Partition the data into training (until November 31, 2017) and test sets (December 2017) Task 2: Build and train an LSTM network1. Create an input layer with a varying sequence length and 24 features2. Create an LSTM layer with ReLU activation function and Sigmoid recurrent activation function3. Create a dense layer with ReLU activation function4. Train the LSTM network using mean squared error as the loss function Task 3: Execute and evaluate the LSTM network1. Execute the network on the test data2. Convert the output column to integer3. Evaluate the predictions with a line plot and with scoring metrics readnyc-taxi-data.csv CSV Reader Task 1: Preprocess the data1. Convert the pickup_timestamp column into Date&Time2. Sort the data by time in ascending order3. Create 24 columns for the 24 past hours' trip counts4. Create a collection column of these past values5. Partition the data into training (until November 31, 2017) and test sets (December 2017) Task 2: Build and train an LSTM network1. Create an input layer with a varying sequence length and 24 features2. Create an LSTM layer with ReLU activation function and Sigmoid recurrent activation function3. Create a dense layer with ReLU activation function4. Train the LSTM network using mean squared error as the loss function Task 3: Execute and evaluate the LSTM network1. Execute the network on the test data2. Convert the output column to integer3. Evaluate the predictions with a line plot and with scoring metrics readnyc-taxi-data.csv CSV Reader

Nodes

Extensions

Links