I'm currently training my first neural network on a larger dataset. I have splitted my training data to several .npy binary files, that each contain batches of 20k training samples. I'm loading the data from the npy files, apply some simple pre-processing operations, and then start to train my network by applying the partial_fit method several times in a loop:
for i in range(50):
nnmodel.partial_fit(X_tr,Y_tr)
I read already, that the regular .fit() method is not capable of training with multiple batches, but partial_fit in contrary should be able to do it.. My first training run goes always well. The loss is decreasing, and I get nice fitting results, so I save my model using the joblib.dump method.
For the next call I'm using exactly the same script again, that loads my data from the .npy files (doesn't matter if I feed the same batch, or another one), pre-process it, this time load my pre-trained model with joblib.load, and start doing the partial_fit loop again.
What I always get in the second run is a constant loss over all iterations, the error is not decreasing anymore, no matter what dataset I use:
Iteration 51, loss = 3.93268978
Iteration 52, loss = 3.93268978
Iteration 53, loss = 3.93268978
Iteration 54, loss = 3.93268978 ...
What am I doing wrong here? Thanks already!
