Convolutional Neural Network – How to Code Some of the Critical Steps

While I was writing my custom program, I realized that some of the functions could be a little tricky to handle. I tried to make this article not just another article on how CNN works or the mathematics behind it, but more about some of the techniques on how data is structured/formatted while it moves from the convolution layers to maxpool, to the fully connected layer, and back again.

I will take an example to explain how the convolve, max pool, FC, and backpropagation datasets will look with details on some of the key functions

Forward and Back-Propagation Programming Technique/Steps to Train an Artificial Neural Net

This write-up is especially for those who want to try their hands at coding an Artificial Neural Net. How it is done mathematically doesn’t need an explanation from someone like me who is a programmer and not a scientist or a researcher. There are numerous training videos that you can go through and learn. I have gone through Prof Patrick Winston’s class as part of MIT OpenCourseWare and understood how the feed-forward and back-propagation technique works.

Through this article, I will explain the steps that you will need to follow to build a fully configurable ANN program (with N number of input features, N number of hidden layers, N number of neurons in each hidden layer, N number of output neurons). I would encourage to write your own custom program following the steps. As long as we adhere to the best practices of programming, test its efficiency, performance, we are good to go.