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


Python EDJob.stats方法代码示例

本文整理汇总了Python中EDJob.EDJob.stats方法的典型用法代码示例。如果您正苦于以下问题:Python EDJob.stats方法的具体用法?Python EDJob.stats怎么用?Python EDJob.stats使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在EDJob.EDJob的用法示例。


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

示例1: waitForAllProcessToFinish

# 需要导入模块: from EDJob import EDJob [as 别名]
# 或者: from EDJob.EDJob import stats [as 别名]
 def waitForAllProcessToFinish(self):
     """
     as it names says, this method waits for all plug-ins which are currently running to finish before returning.
     """
     self.screen("Waiting for launched jobs to finish .")
     while (self.getNbRunning() > 0):
         time.sleep(1)
         sys.stderr.write(".")
     sys.stderr.write("Done.\n")
     EDJob.stats()
开发者ID:jordiandreu,项目名称:edna-mx,代码行数:12,代码来源:EDParallelExecute.py

示例2: process

# 需要导入模块: from EDJob import EDJob [as 别名]
# 或者: from EDJob.EDJob import stats [as 别名]
 def process(self):
     for fn in self.dataFiles:
         EDVerbose.screen("Processing file %s" % fn)
         edj = EDJob(self.EDNAPluginName)
         edj.dataInput = self.fileName2xml(fn)
         edj.connectSUCCESS(self.XMLsuccess)
         edj.connectFAILURE(self.XMLerr)
         self.queue.put(edj)
         if self.process_sem._Semaphore__value > 0 :
             t = threading.Thread(target=self.startProcessing)
             t.start()
     EDVerbose.screen("Back in main")
     while self.cpu_sem._Semaphore__value < self.nbcpu:
         time.sleep(0.1)
     EDJob.synchronizeAll()
     EDJob.stats()
开发者ID:kif,项目名称:edna,代码行数:18,代码来源:AzimuthalIntegration.py

示例3: statistics

# 需要导入模块: from EDJob import EDJob [as 别名]
# 或者: from EDJob.EDJob import stats [as 别名]
 def statistics(self):
     """
     retrieve some statistics about past jobs.
     """
     with self.statLock:
         fStartStat = time.time()
         self.lastStatistics = EDJob.stats()
         self.lastStatistics += os.linesep + "Statistics collected on %s, the collect took: %.3fs" % (time.asctime(), time.time() - fStartStat)
     return self.lastStatistics
开发者ID:gbourgh,项目名称:edna,代码行数:11,代码来源:analysis_modeling.py

示例4: findFile

# 需要导入模块: from EDJob import EDJob [as 别名]
# 或者: from EDJob.EDJob import stats [as 别名]
                if os.path.isfile(myPluginPath):
                    listOfPythonFiles = [myPluginPath]
                for onePyFile in findFile(pluginPath):
                    if not onePyFile in listOfPythonFiles:
                        listOfPythonFiles.append(onePyFile)
                if len(listOfPythonFiles) > 0:
                    epydocJob = EDJob("EDPluginExecEpydocv1_0")
                    dictJobs[oneplugin] = epydocJob
                    xsd = XSDataInputEpydoc()
                    xsd.setDocPath(XSDataFile(XSDataString(docPath)))
                    xsd.setProjectName(XSDataString(oneplugin))
                    xsd.setDocType(XSDataString(docFormat))
                    if bVerbose:
                        xsd.setVerbosity(XSDataInteger(2))
                    else:
                        xsd.setVerbosity(XSDataInteger(-1))
                    xsd.setSources([XSDataFile(XSDataString(oneFile)) for oneFile in listOfPythonFiles])
                    epydocJob.setDataInput(xsd)
                    epydocJob.execute()
                else:
                    print ("Error: No python files for plugin %s" % oneplugin)
    EDVerbose.screen("Back to main")
    for jobName in dictJobs:
        job = dictJobs[jobName]
        if job.getStatus() in [EDJob.PLUGIN_STATE_RUNNING, EDJob.PLUGIN_STATE_UNITIALIZED]:
            EDVerbose.screen("Waiting for job %s to finish" % jobName)
            job.synchronize()
    EDVerbose.screen("Generation of documentation finished")
    os.chdir(cwd)
    EDJob.stats()
开发者ID:gbourgh,项目名称:edna,代码行数:32,代码来源:DocGenerator.py


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