021f346839bbab5b22e5858eab16d382af26185b,autokeras/auto_model.py,AutoModel,predict,#AutoModel#Any#Any#,149

Before Change


            **kwargs: Any arguments supported by keras.Model.predict.
        
        x = utils.prepare_preprocess(x, x)
        x = self.hypermodel.preprocess(self.tuner.get_best_hp(1), x)
        x = x.batch(batch_size)
        y = self.tuner.get_best_models(1)[0].predict(x, **kwargs)
        y = nest.flatten(y)
        y = self._postprocess(y)

After Change


        
        best_model = self.tuner.get_best_models(1)[0]
        best_hp = self.tuner.get_best_hp(1)[0]
        best_trial = self.tuner.get_best_trials(1)[0]
        filename = "%s-preprocessors" % best_trial.trial_id
        path = os.path.join(best_trial.directory, filename)

        self.hypermodel.load_preprocessors(path)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: jhfjhfj1/autokeras
Commit Name: 021f346839bbab5b22e5858eab16d382af26185b
Time: 2019-07-30
Author: jhfjhfj1@gmail.com
File Name: autokeras/auto_model.py
Class Name: AutoModel
Method Name: predict


Project Name: explosion/thinc
Commit Name: 0f34c5acbe4e2d6af8f545538aa52edb70ba6e80
Time: 2017-03-12
Author: honnibal+gh@gmail.com
File Name: examples/linear_bow.py
Class Name:
Method Name: main