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.
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)
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.