ffa0db4fdca9cef31a72b35a1f7eef78733f5b0c,glyph/cli/glyph_remote.py,RemoteAssessmentRunner,update_fitness,#RemoteAssessmentRunner#Any#Any#,239

Before Change


        if self.send_all:
            calculate_fitness = self.evaluate_all(population)
        else:
            calculate_fitness = [self.measure(ind) for ind in calculate]

        // save to cache
        for key, fit in zip(map(self._hash, calculate), calculate_fitness):
            self.cache[key] = fit

After Change


            thread = Thread(target=self.queue.run)
            thread.start()
            with concurrent.futures.ThreadPoolExecutor(max_workers=len(calculate)) as executor:
                futures = {executor.submit(self.measure, ind): ind for ind in calculate}
                for future in futures:
                    calculate_fitness.append(future.result())
            thread.join()
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: Ambrosys/glyph
Commit Name: ffa0db4fdca9cef31a72b35a1f7eef78733f5b0c
Time: 2017-02-24
Author: mquade@uni-potsdam.de
File Name: glyph/cli/glyph_remote.py
Class Name: RemoteAssessmentRunner
Method Name: update_fitness


Project Name: analysiscenter/batchflow
Commit Name: f655fd8ff333159ffa88e1dfbcf2e32f706c9d97
Time: 2017-04-19
Author: rhudor@gmail.com
File Name: dataset/pipeline.py
Class Name: Pipeline
Method Name: run


Project Name: studioml/studio
Commit Name: 13986978d4545aa429a7fc233d8e39718d52e255
Time: 2020-08-11
Author: andrei.denissov@cognizant.com
File Name: studio/keyvalue_provider.py
Class Name: KeyValueProvider
Method Name: checkpoint_experiment