O'Reilly logo

Scala Machine Learning Projects by Md. Rezaul Karim

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Training the CNNs and saving the trained models

So far, we have seen how to prepare the training set; now we have a challenge ahead. We have to train 234,545 images. Although the testing phase would be less exhaustive with only 500 images, it's better to train each CNN using batch-mode using DL4j's MultipleEpochsIterator. Here's a list of important hyperparameters and their details:

  • Layers: As we have already observed with our simple 5 layers MNIST, we received outstanding classification accuracy, which is very promising. Here I will try to construct a similar network having.
  • The number of samples: If you're training all the images, it will take too long. If you train using the CPU, not the GPU, it will take days. When I tried with 50,000 ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required