In this chapter, we are going to develop a convolutional neural network (CNN) for an image classification example using DL4J. We will develop the components of our application step by step while we progress through the recipes. The chapter assumes that you have read Chapter 1, Introduction to Deep Learning in Java, and Chapter 2, Data Extraction, Transformation, and Loading, and that you have set up DL4J on your computer, as mentioned in Chapter 1, Introduction to Deep Learning in Java. Let's go ahead and discuss the specific changes required for this chapter.
For demonstration purposes, we will have classifications for four different species. CNNs convert complex images into an abstract format that can be used for prediction. Hence, a CNN would be an optimal choice for this image classification problem.
CNNs are just like any other...