b5e906b0b31d0de66caa51e4ae3bbad93303d1f5,cifar100.py,,,#,4

Before Change


// print("Model loaded.")

model.fit_generator(generator.flow(trainX, Y_train, batch_size=batch_size), samples_per_epoch=len(trainX), nb_epoch=nb_epoch,
                   callbacks=[ModelCheckpoint("weights/DenseNet-BC-100-12-CIFAR100.h5", monitor="val_acc", save_best_only=True,
                                              save_weights_only=True)],
                   validation_data=(testX, Y_test),
                   nb_val_samples=testX.shape[0], verbose=2)

After Change


lr_reducer      = ReduceLROnPlateau(monitor="val_loss", factor=np.sqrt(0.1),
                                    cooldown=0, patience=10, min_lr=0.5e-6)
early_stopper   = EarlyStopping(monitor="val_acc", min_delta=0.0001, patience=20)
model_checkpoint= ModelCheckpoint("weights/DenseNet-BC-100-12-CIFAR100.h5", monitor="val_acc", save_best_only=True,
                                  save_weights_only=True)

callbacks=[lr_reducer, early_stopper, model_checkpoint]


model.fit_generator(generator.flow(trainX, Y_train, batch_size=batch_size), samples_per_epoch=len(trainX), nb_epoch=nb_epoch,
                   callbacks=callbacks,
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: titu1994/DenseNet
Commit Name: b5e906b0b31d0de66caa51e4ae3bbad93303d1f5
Time: 2017-04-25
Author: titu1994@gmail.com
File Name: cifar100.py
Class Name:
Method Name:


Project Name: divamgupta/image-segmentation-keras
Commit Name: d0eee0ee4824482e22a6694d18379e90ec61af3f
Time: 2021-01-16
Author: Marius.juston@hotmail.fr
File Name: keras_segmentation/train.py
Class Name:
Method Name: train


Project Name: williamFalcon/pytorch-lightning
Commit Name: 8e9a026bc34d8409faa572a7144c2d96a7c039ed
Time: 2021-02-11
Author: rohitgr1998@gmail.com
File Name: tests/models/test_restore.py
Class Name:
Method Name: test_dp_resume