After the model has been trained by reducing the error rate, the validation set (e.g., 7,000 images of 4 drivers) may then be input to test the updated model, which can give different output probabilities that are more accurate with respect to the actual images, e.g., 0.4, 0.2, and 0.4 for respective classes “safe driving,” “texting,” and “calling.” In this way, the validation set can be used to further train the CNN model to classify particular images correctly by adjusting the model's weights or filters such that the output error is further reduced. In some embodiments, parameters like the number of filters, filter sizes, architecture of the network may all have been fixed before the CNN model is trained and, thus, would not require updates during training process. In such an embodiment, only the values associated with the filters and weights of the CNN get updated.
Finally, the test data set (e.g., 5,000 images of 6 drivers) may then be used to further determine the accuracy of the CNN model, e.g., whether and to what extent the CNN model correctly classifies new images.
In some embodiments, each of the training, testing, and validation stages may use multiple batches or cycles of images from each data set to train, validate or otherwise test the CNN model. For example, the CNN model may be trained during the training stage using 1000 images from the 67,000 images in the training data set thereby requiring 67 cycles, or batches, to fully train and prepare the CNN model for the validation stage.