0
$\begingroup$

I am working on character recognition using convolutional neural networks. I have 9 layer model and 19990 training data and 4470 test data. But when I am using keras with Tensorflow backend. When I try to train the model, it runs extremely slow, like 100-200 samples per minute. I tried adding batch normalization layer after flattening, using regularization, adding dropout layers, using fit_generator to load data from disk batch wise so that ram remain free(that did the worse performance) using different batch sizes, but nothing is working. So, I tried reducing network size to 4 layers and added more channels to initial layers to increase parallel computing but now I started getting memory allocation errors. It says allocation of some address exceeds 10% and than my entire system freezes. I have to restart my laptop every time. I tried going back to the earlier version with 9 layers but that is giving me same error as well now, even though it worked earlier(not really worked, but atleast started training). So, what is the solution for this problem? Is it the problem of hardware being less capable or something else? I have 8gb ram and 2 gb gpu, but i dont use gpu for training. I have intel i5 7gen processor.

$\endgroup$
0
$\begingroup$

It seems like your hardware is just not strong enough...

Training neural networks require serious computational capabilities, which are not available at standard laptops. This is not a problem that you can solve. Using your available hardware, training would simply take a lot of time. (sorry buddy)

$\endgroup$
  • $\begingroup$ so will upgrading my ram help? I cannot upgrade my gpu as gpu is not upgradable in laptops. I have 8 gb ram so will 16 gb do? $\endgroup$ – Shantanu Shinde Dec 9 '18 at 4:42
  • $\begingroup$ It won't help enough to make it relevant. $\endgroup$ – Mark.F Dec 9 '18 at 8:35
  • $\begingroup$ so only option to practice machine learning is get high end pc? $\endgroup$ – Shantanu Shinde Dec 9 '18 at 8:51
  • $\begingroup$ You can also pay to use one of the cloud services like AWS (amazon), Google Cloud Compute, Microsoft Azure etc. Or if practice is your intention, choose less demanding challenges and smaller networks. $\endgroup$ – Mark.F Dec 9 '18 at 9:22
  • $\begingroup$ which platform do you suggest out of the 3? which has better performance? $\endgroup$ – Shantanu Shinde Dec 9 '18 at 13:03
0
$\begingroup$

As stated by "Mark.F" you are suffering from hardware insufficiency. Event raining a simple network is a difficult task for CPUs. You can check your GPU compatibility from this link. Remember that none of the machine learning frameworks does not support parallel processing on GPUs which CUDA compute capability is lower than 3.0.

$\endgroup$
  • $\begingroup$ will upgrading ram to 16 gb do, as gpu cannot be upgraded in laptop. $\endgroup$ – Shantanu Shinde Dec 9 '18 at 7:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.