8bed5224060ae8f46ab7439cfa28cd134de1dd2e,python/paddle_edl/utils/edl_env.py,JobEnv,__init__,#JobEnv#Any#Any#Any#,17

Before Change



class JobEnv(object):
    def __init__(self, etcd_endoints=None, job_id=None, master=None):
        self.running_env = os.getenv("PADDLE_RUNING_ENV")
        self.job_id = os.getenv("PADDLE_JOB_ID") if job_id is None else job_id
        self.master = os.getenv("PADDLE_MASTER") if master is None else master
        self.etcd_endpoints = os.getenv(
            "PADDLE_EDL_ETCD_ENPOINTS"

After Change


        ports = os.getenv(
            "PADDLE_TRAINER_PORTS") if trainer_ports is None else trainer_ports
        assert ports, "PADDLE_TRAINER_PORTS must has valid value"
        self.trainer_ports = ports.split(",")
        assert len(self.trainer_ports) == gpu_num, "one gpu one port"


class TrainerEnv(object):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: PaddlePaddle/edl
Commit Name: 8bed5224060ae8f46ab7439cfa28cd134de1dd2e
Time: 2020-05-18
Author: weibao.gong@gmail.com
File Name: python/paddle_edl/utils/edl_env.py
Class Name: JobEnv
Method Name: __init__


Project Name: ray-project/ray
Commit Name: c5cde65bc6974e9f1f13c4ea5cdb7beca93f6148
Time: 2020-07-21
Author: mehrdadn@users.noreply.github.com
File Name: python/setup.py
Class Name:
Method Name: build


Project Name: nilearn/nilearn
Commit Name: 9df22084c5753cd5b3480afddee054dcdd774438
Time: 2017-05-29
Author: dkamalakarreddy@gmail.com
File Name: nilearn/datasets/atlas.py
Class Name:
Method Name: fetch_atlas_harvard_oxford