8cadb9c4b723cb9bd097234cfa739f9281945477,agents/a3c.py,A3C,learn,#A3C#,59

Before Change


        ps_process = subprocess.Popen([sys.executable, os.path.join(current_folder, "parameter_server.py"), str(self.config["n_tasks"])])
        worker_processes = []
        for task_id in range(self.config["n_tasks"]):
            p = subprocess.Popen([
                sys.executable,
                os.path.join(current_folder, "a3c_worker.py"),
                self.env_name,
                self.thread_type,
                str(task_id),
                str(self.config["n_tasks"]),
                self.config["config_path"],
                "--monitor_path", self.monitor_path
            ])
            worker_processes.append(p)
        for p in worker_processes:
            p.wait()
        ps_process.terminate()

After Change


                self.config["config_path"],
                "--monitor_path", self.monitor_path
            ]
            processed_cmd = " ".join(shlex_quote(str(x)) for x in cmd)
            p = subprocess.Popen(processed_cmd, shell=True)
            worker_processes.append(p)
        for p in worker_processes:
            p.wait()
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: arnomoonens/yarll
Commit Name: 8cadb9c4b723cb9bd097234cfa739f9281945477
Time: 2018-02-13
Author: arno.moonens@outlook.com
File Name: agents/a3c.py
Class Name: A3C
Method Name: learn


Project Name: bjherger/ResumeParser
Commit Name: e08fcab00157590859a9a19bd483825e9ba75c18
Time: 2019-03-29
Author: 13herger@gmail.com
File Name: bin/lib.py
Class Name:
Method Name: convert_pdf


Project Name: pantsbuild/pants
Commit Name: 3d7c03ab5a7fcd2459128d9cc849031b28b3f350
Time: 2015-10-12
Author: john.sirois@gmail.com
File Name: tests/python/pants_test/backend/jvm/tasks/test_binary_create_integration.py
Class Name: BinaryCreateIntegrationTest
Method Name: test_deploy_excludes


Project Name: cjekel/tindetheus
Commit Name: c2b8f83752d502c52bb8d4d70e3aae40525bf7f2
Time: 2018-04-09
Author: cjekel@gmail.com
File Name: tindetheus/facenet_clone/facenet.py
Class Name:
Method Name: store_revision_info