self._total_time = time.time() - start_time - time_callback.times[0]
// Save model and weights
if not os.path.isdir(save_dir):
os.makedirs(save_dir)
model_path = os.path.join(save_dir, model_name)
model.save(model_path)
print("Saved trained model at %s " % model_path)
After Change
// initiate RMSprop optimizer
opt = keras.optimizers.rmsprop(lr=0.0001, decay=1e-6)
if str(keras_backend) is "tensorflow" and gpu_count > 1:
model = multi_gpu_model(model, gpus=gpu_count)
// Let"s train the model using RMSprop