9fd84ad62217e80e521f755c151a2d1dbc9ebe2d,autokeras/search.py,Searcher,load_best_model,#Searcher#,55

Before Change



    def load_best_model(self):
        return model with best accuracy
        model_id = max(self.history, key=lambda x: x["accuracy"])["model_id"]
        return load_model(os.path.join(self.path, str(model_id) + ".h5"))

    def add_model(self, model, x_train, y_train, x_test, y_test):
        add one model while will be trained to history list

After Change



    def load_best_model(self):
        return model with best accuracy
        return self.load_model_by_id(max(self.history, key=lambda x: x["accuracy"])["model_id"])

    def add_model(self, model, x_train, y_train, x_test, y_test):
        add one model while will be trained to history list
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: jhfjhfj1/autokeras
Commit Name: 9fd84ad62217e80e521f755c151a2d1dbc9ebe2d
Time: 2018-03-09
Author: jhfjhfj1@gmail.com
File Name: autokeras/search.py
Class Name: Searcher
Method Name: load_best_model


Project Name: ClimbsRocks/auto_ml
Commit Name: e87334a5fbe16bd1f16357b452036b578ca3b5f8
Time: 2017-04-17
Author: ClimbsBytes@gmail.com
File Name: auto_ml/utils_models.py
Class Name:
Method Name: load_keras_model