I am training large amount of data using a CNN. I am not using a default keras generator but reading images batch by batch in a for loop and in each iteration using model.fit(). The official tutorial tells me that when using model.fit() use nb_epoch = 1. What is the reason for that? If i give nb_epochs as 10 or something. Will the model re initialize the weights during every iteration or will it update the weights.
This is the sample code:
for e in range(234):
x,y = getdata(1000,e)
x = x.astype('float32')
x = x/255
model.fit(x,y,nb_epoch = 10)
getdata() returns 1000 images. So my question is for each 1000 images, does the model update weights or not? Or does it reinitialize weights every iteration.
Successive calls to fit do not reinitialize the weights.
Most helpful comment
Successive calls to
fitdo not reinitialize the weights.