ee82275868049880a4ca9d4a9c05236c58bfe2d2,elfi/methods/methods.py,BayesianOptimization,prepare_new_batch,#BayesianOptimization#Any#,364

Before Change



    def prepare_new_batch(self, batch_index):
        context = self.model.computation_context
        pending_batches = context.output_supply[self.model.parameters[0]]

        // TODO: take values from the pool
        pending_params = []
        for output in pending_batches.values():

After Change


            new_param = self.init_acquisition.acquire(1, pending_params, t)

        // Save the next evaluation location to the pool
        self.pool.add_batch(batch_index, dict(zip(self.parameters, new_param[0])))

    def extract_result(self):
        param, min_value = stochastic_optimization(self.target_model.predict_mean,
                                                   self.target_model.bounds)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: elfi-dev/elfi
Commit Name: ee82275868049880a4ca9d4a9c05236c58bfe2d2
Time: 2017-03-30
Author: jarno.lintusaari@aalto.fi
File Name: elfi/methods/methods.py
Class Name: BayesianOptimization
Method Name: prepare_new_batch


Project Name: ray-project/ray
Commit Name: 2298f6fb40cb6d348b5b48593c93cdd58ddd1f29
Time: 2020-04-23
Author: ekhliang@gmail.com
File Name: rllib/execution/replay_ops.py
Class Name: StoreToReplayBuffer
Method Name: __call__


Project Name: ray-project/ray
Commit Name: 96f4d82cc3554875ca493256a020e2be4c9f6f2f
Time: 2020-05-12
Author: ekhliang@gmail.com
File Name: rllib/execution/replay_ops.py
Class Name: MixInReplay
Method Name: __call__