2733bef356c53286d475a67476d88d4840923830,code/deep/finetune_AlexNet_ResNet/finetune_office31.py,,finetune,#,87

Before Change


            if phase == "tar" and epoch_acc > best_acc:
                best_acc = epoch_acc
        print()
        fname = "finetune_result" + model_name + \
            str(LEARNING_RATE) + str(args.source) + \
            "-" + str(args.target) + ".csv"
        np.savetxt(fname, np.asarray(a=acc_hist, dtype=float), delimiter=",",
                   fmt="%.4f")
    time_pass = time.time() - since
    print("Training complete in {:.0f}m {:.0f}s".format(

After Change


            if phase == "val" and epoch_acc > best_acc:
                stop = 0
                best_acc = epoch_acc
                torch.save(model.state_dict(), "model.pkl")
        if stop >= args.early_stop:
            break
        print()
    model.load_state_dict(torch.load("model.pkl"))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: jindongwang/transferlearning
Commit Name: 2733bef356c53286d475a67476d88d4840923830
Time: 2020-09-30
Author: jindongwang@outlook.com
File Name: code/deep/finetune_AlexNet_ResNet/finetune_office31.py
Class Name:
Method Name: finetune


Project Name: openai/pixel-cnn
Commit Name: 0327b8fe3434e91f9090e50aa1fade8c36ef8d79
Time: 2016-07-12
Author: tim@Tims-MacBook-Pro.local
File Name: train_double_cnn.py
Class Name:
Method Name:


Project Name: openai/pixel-cnn
Commit Name: 32be8e1eeb02497ea4dc2547618bde279006b445
Time: 2016-07-12
Author: tim@Tims-MacBook-Pro.local
File Name: train_row_lstm.py
Class Name:
Method Name: