当前位置: 首页>>代码示例>>Python>>正文


Python ComputingElement.ComputingElement类代码示例

本文整理汇总了Python中DIRAC.Resources.Computing.ComputingElement.ComputingElement的典型用法代码示例。如果您正苦于以下问题:Python ComputingElement类的具体用法?Python ComputingElement怎么用?Python ComputingElement使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了ComputingElement类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: _addCEConfigDefaults

  def _addCEConfigDefaults( self ):
    """Method to make sure all necessary Configuration Parameters are defined
    """
    # First assure that any global parameters are loaded
    ComputingElement._addCEConfigDefaults( self )
    # Now batch system specific ones
    if 'ExecQueue' not in self.ceParameters:
      self.ceParameters['ExecQueue'] = self.ceParameters.get( 'Queue', '' )

    if 'SharedArea' not in self.ceParameters:
      defaultPath = os.environ.get( 'HOME', '.' )
      self.ceParameters['SharedArea'] = gConfig.getValue( '/LocalSite/InstancePath', defaultPath )

    if 'BatchOutput' not in self.ceParameters:
      self.ceParameters['BatchOutput'] = 'data'

    if 'BatchError' not in self.ceParameters:
      self.ceParameters['BatchError'] = 'data'

    if 'ExecutableArea' not in self.ceParameters:
      self.ceParameters['ExecutableArea'] = 'data'

    if 'InfoArea' not in self.ceParameters:
      self.ceParameters['InfoArea'] = 'info'

    if 'WorkArea' not in self.ceParameters:
      self.ceParameters['WorkArea'] = 'work'
开发者ID:DIRACGrid-test,项目名称:DIRAC,代码行数:27,代码来源:LocalComputingElement.py

示例2: __init__

 def __init__(self, ceUniqueID):
     """ Standard constructor.
 """
     ComputingElement.__init__(self, ceUniqueID)
     self.ceType = CE_NAME
     self.submittedJobs = 0
     self.mandatoryParameters = MANDATORY_PARAMETERS
     self.pilotProxy = ""
     self.queue = ""
     self.outputURL = "gsiftp://localhost"
     self.gridEnv = ""
     self.ceHost = self.ceName
     self.usercfg = arc.common.UserConfig()
     if "Host" in self.ceParameters:
         self.ceHost = self.ceParameters["Host"]
     if "GridEnv" in self.ceParameters:
         self.gridEnv = self.ceParameters["GridEnv"]
     # Used in getJobStatus
     self.mapStates = {
         "Accepted": "Scheduled",
         "Preparing": "Scheduled",
         "Submitting": "Scheduled",
         "Queuing": "Scheduled",
         "Hold": "Scheduled",
         "Undefined": "Unknown",
         "Running": "Running",
         "Finishing": "Running",
         "Deleted": "Killed",
         "Killed": "Killed",
         "Failed": "Failed",
         "Finished": "Done",
         "Other": "Done",
     }
     self.__getXRSLExtraString()  # Do this after all other initialisations, in case something barks
开发者ID:vipersec,项目名称:DIRAC,代码行数:34,代码来源:ARCComputingElement.py

示例3: _addCEConfigDefaults

  def _addCEConfigDefaults( self ):
    """Method to make sure all necessary Configuration Parameters are defined
    """
    # First assure that any global parameters are loaded
    ComputingElement._addCEConfigDefaults( self )
    # Now batch system specific ones
    if 'ExecQueue' not in self.ceParameters:
      self.ceParameters['ExecQueue'] = self.ceParameters.get( 'Queue', '' )

    if 'SharedArea' not in self.ceParameters:
      self.ceParameters['SharedArea'] = '.'

    if 'BatchOutput' not in self.ceParameters:
      self.ceParameters['BatchOutput'] = 'data' 

    if 'BatchError' not in self.ceParameters:
      self.ceParameters['BatchError'] = 'data' 

    if 'ExecutableArea' not in self.ceParameters:
      self.ceParameters['ExecutableArea'] = 'data' 

    if 'InfoArea' not in self.ceParameters:
      self.ceParameters['InfoArea'] = 'info'
      
    if 'WorkArea' not in self.ceParameters:
      self.ceParameters['WorkArea'] = 'work'  
      
    if 'SubmitOptions' not in self.ceParameters:
      self.ceParameters['SubmitOptions'] = '-'    
开发者ID:cgrefe,项目名称:DIRAC,代码行数:29,代码来源:SSHComputingElement.py

示例4: __init__

 def __init__( self, ceUniqueID ):
   """ Standard constructor.
   """
   ComputingElement.__init__( self, ceUniqueID )
   self.ceType = CE_NAME
   self.submittedJobs = 0
   self.mandatoryParameters = MANDATORY_PARAMETERS
   self.pilotProxy = ''
   self.queue = ''
   self.outputURL = 'gsiftp://localhost'
   self.gridEnv = ''
   self.ceHost = self.ceName
   self.usercfg = arc.common.UserConfig()
   if 'Host' in self.ceParameters:
     self.ceHost = self.ceParameters['Host']
   if 'GridEnv' in self.ceParameters:
     self.gridEnv = self.ceParameters['GridEnv']
   # Used in getJobStatus
   self.mapStates = { 'Accepted'   : 'Scheduled',
                      'Preparing'  : 'Scheduled',
                      'Submitting' : 'Scheduled',
                      'Queuing'    : 'Scheduled',
                      'Hold'       : 'Scheduled',
                      'Undefined'  : 'Unknown',
                      'Running'    : 'Running',
                      'Finishing'  : 'Running',
                      'Deleted' : 'Killed',
                      'Killed'  : 'Killed',
                      'Failed'  : 'Failed',
                      'Finished': 'Done',
                      'Other'   : 'Done'
     }
   self.__getXRSLExtraString() # Do this after all other initialisations, in case something barks
开发者ID:JanEbbing,项目名称:DIRAC,代码行数:33,代码来源:ARCComputingElement.py

示例5: __init__

 def __init__( self, ceUniqueID ):
   """ Standard constructor.
   """
   ComputingElement.__init__( self, ceUniqueID )
   
   self.ceType = CE_NAME
   self.submittedJobs = 0
   self.mandatoryParameters = MANDATORY_PARAMETERS
开发者ID:KrzysztofCiba,项目名称:DIRAC,代码行数:8,代码来源:SSHTorqueComputingElement.py

示例6: __init__

 def __init__( self, ceUniqueID ):
   """ Standard constructor.
   """
   ComputingElement.__init__( self, ceUniqueID )
   self.minProxyTime = gConfig.getValue( '/Registry/MinProxyLifeTime', 10800 ) #secs
   self.defaultProxyTime = gConfig.getValue( '/Registry/DefaultProxyLifeTime', 86400 ) #secs
   self.proxyCheckPeriod = gConfig.getValue( '/Registry/ProxyCheckingPeriod', 3600 ) #secs
   self.submittedJobs = 0
开发者ID:NathalieRauschmayr,项目名称:DIRAC,代码行数:8,代码来源:glexecComputingElement.py

示例7: __init__

  def __init__( self, ceUniqueID ):
    """ Standard constructor.
    """
    ComputingElement.__init__( self, ceUniqueID )

    self.ceType = CE_NAME
    self.controlScript = ''
    self.finalScript = ''
    self.submittedJobs = 0
    self.userName = getpass.getuser()
    self.mandatoryParameters = MANDATORY_PARAMETERS
开发者ID:SimonBidwell,项目名称:DIRAC,代码行数:11,代码来源:LocalComputingElement.py

示例8: __init__

  def __init__( self, ceUniqueID ):
    """ Standard constructor.
    """
    ComputingElement.__init__( self, ceUniqueID )

    self.ceType = ''
    self.execution = "Local"
    self.batchSystem = self.ceParameters.get( 'BatchSystem', 'Host' )
    self.batchModuleFile = None
    self.submittedJobs = 0
    self.userName = getpass.getuser()
开发者ID:DIRACGrid-test,项目名称:DIRAC,代码行数:11,代码来源:LocalComputingElement.py

示例9: __init__

  def __init__( self, ceUniqueID ):
    """ Standard constructor.
    """
    ComputingElement.__init__( self, ceUniqueID )

    self.ceType = 'SSH'
    self.execution = "SSH"
    self.batchSystem = 'Host'
    self.submittedJobs = 0
    self.outputTemplate = ''
    self.errorTemplate = ''
开发者ID:Kiyoshi-Hayasaka,项目名称:DIRAC,代码行数:11,代码来源:SSHComputingElement.py

示例10: __init__

  def __init__( self, ceUniqueID ):
    """ Standard constructor.
    """
    ComputingElement.__init__( self, ceUniqueID )

    self.ceType = CE_NAME
    self.submittedJobs = 0
    self.mandatoryParameters = MANDATORY_PARAMETERS
    self.pilotProxy = ''
    self.queue = ''
    self.outputURL = 'gsiftp://localhost'
    self.gridEnv = ''
开发者ID:hanyl,项目名称:DIRAC,代码行数:12,代码来源:CREAMComputingElement.py

示例11: __init__

  def __init__( self, ceUniqueID ):
    """ Standard constructor.
    """

    ComputingElement.__init__( self, ceUniqueID )

    self.ceType = CE_NAME
    self.mandatoryParameters = []
    self.wsdl = None
    self.BOINCClient = None
#define a job prefix based on the wsdl url
    self.suffix = None
开发者ID:DIRACGrid-test,项目名称:DIRAC,代码行数:12,代码来源:BOINCComputingElement.py

示例12: __init__

 def __init__(self, ceUniqueID):
   """ Standard constructor.
   """
   ComputingElement.__init__(self, ceUniqueID)
   self.ceType = "Pool"
   self.log = gLogger.getSubLogger('Pool')
   self.submittedJobs = 0
   self.processors = 1
   self.pPool = None
   self.taskID = 0
   self.processorsPerTask = {}
   self.userNumberPerTask = {}
   self.useSudo = False
开发者ID:DIRACGrid,项目名称:DIRAC,代码行数:13,代码来源:PoolComputingElement.py

示例13: __init__

  def __init__( self, ceUniqueID ):
    """ Standard constructor.
    """
    ComputingElement.__init__( self, ceUniqueID )
    self.submittedJobs = 0

    self.queue = self.ceConfigDict['Queue']
    self.execQueue = self.ceConfigDict['ExecQueue']
    self.log.info( "Using queue: ", self.queue )
    self.hostname = socket.gethostname()
    self.sharedArea = self.ceConfigDict['SharedArea']
    self.batchOutput = self.ceConfigDict['BatchOutput']
    self.batchError = self.ceConfigDict['BatchError']
开发者ID:caitriana,项目名称:DIRAC,代码行数:13,代码来源:TorqueComputingElement.py

示例14: __init__

    def __init__(self, ceUniqueID):
        """ Standard constructor.
    """
        ComputingElement.__init__(self, ceUniqueID)

        self.ceType = CE_NAME
        self.submittedJobs = 0
        self.mandatoryParameters = MANDATORY_PARAMETERS
        self.pilotProxy = ""
        self.queue = ""
        self.outputURL = "gsiftp://localhost"
        self.gridEnv = ""
        self.ceHost = self.ceName
        if "Host" in self.ceParameters:
            self.ceHost = self.ceParameters["Host"]
        if "GridEnv" in self.ceParameters:
            self.gridEnv = self.ceParameters["GridEnv"]
开发者ID:sposs,项目名称:DIRAC,代码行数:17,代码来源:ARCComputingElement.py

示例15: _addCEConfigDefaults

  def _addCEConfigDefaults( self ):
    """Method to make sure all necessary Configuration Parameters are defined
    """
    # First assure that any global parameters are loaded
    ComputingElement._addCEConfigDefaults( self )
    # Now Torque specific ones
    if 'ExecQueue' not in self.ceConfigDict:
      self.ceConfigDict['ExecQueue'] = self.ceConfigDict['Queue']

    if 'SharedArea' not in self.ceConfigDict:
      self.ceConfigDict['SharedArea'] = ''

    if 'BatchOutput' not in self.ceConfigDict:
      self.ceConfigDict['BatchOutput'] = os.path.join( gConfig.getValue( '/LocalSite/InstancePath', rootPath ), 'data' )

    if 'BatchError' not in self.ceConfigDict:
      self.ceConfigDict['BatchError'] = os.path.join( gConfig.getValue( '/LocalSite/InstancePath', rootPath ), 'data' )
开发者ID:caitriana,项目名称:DIRAC,代码行数:17,代码来源:TorqueComputingElement.py


注:本文中的DIRAC.Resources.Computing.ComputingElement.ComputingElement类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。