Beispiel #1
0
def closeOutReRecoWorkflows(url, workflows):
    for workflow in workflows:
        if 'RelVal' in workflow:
            continue
        if 'TEST' in workflow:
            continue
        datasets = phedexSubscription.outputdatasetsWorkflow(url, workflow)
        closeOutWorkflow = True
        InputDataset = dbsTest.getInputDataSet(url, workflow)
        for dataset in datasets:
            duplicate = False
            closeOutDataset = True
            Percentage = PercentageCompletion(url, workflow, dataset)
            PhedexSubscription = testOutputDataset(dataset)
            closeOutDataset = False
            if Percentage == 1 and PhedexSubscription and not duplicate:
                closeOutDataset = True
            else:
                closeOutDataset = False
            closeOutWorkflow = closeOutWorkflow and closeOutDataset
            print '| %80s | %100s | %4s | %5s| %3s | %5s|%5s| ' % (
                workflow, dataset, str(int(Percentage * 100)),
                str(PhedexSubscription), 100, duplicate, closeOutDataset)
        if closeOutWorkflow:
            phedexSubscription.closeOutWorkflow(url, workflow)
    print '----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------'
def getListUnprocessedBlocks(url, workflow):
    outputDataSets=phedexSubscription.outputdatasetsWorkflow(url, workflow)
    inputDataset=dbsTest.getInputDataSet(url, workflow)
    lumisOutput=getLumisInDataset(outputDataSets[0])
    BlockLumisInput=getBlocksLumi(inputDataset)
    BlocksNotProcessed=getBlocksNotProcessed(lumisOutput, BlockLumisInput)
    return BlocksNotProcessed
Beispiel #3
0
def runNotinAllDatasets(url, run, workflow):
    Datasets=phedexSubscription.outputdatasetsWorkflow(url, workflow)
    InputDataset=dbsTest.getInputDataSet(url, workflow)
    runInputDataset=runInDataset(url, run, InputDataset)
    if not runInputDataset:
	return True
    for dataset in Datasets:
	if runInDataset(url, run, dataset):#the run is in at least one of the output datasets
		return True
    return False
Beispiel #4
0
def closeOutRedigiWorkflows(url, workflows):
	for workflow in workflows:
		closeOutWorkflow=True
		InputDataset=dbsTest.getInputDataSet(url, workflow)
		datasets=phedexSubscription.outputdatasetsWorkflow(url, workflow)
		for dataset in datasets:
			closeOutDataset=False
			Percentage=PercentageCompletion(url, workflow, dataset)
			PhedexSubscription=testOutputDataset(dataset)
			duplicate=True
			if PhedexSubscription!=False and Percentage>=float(0.95):
				duplicate=dbsTest.duplicateRunLumi(dataset)
			if Percentage>=float(0.95) and PhedexSubscription and not duplicate:
				closeOutDataset=True
			else:
		 		closeOutDataset=False
			closeOutWorkflow=closeOutWorkflow and closeOutDataset
			print '| %80s | %100s | %4s | %5s| %3s | %5s|%5s| ' % (workflow, dataset,str(int(Percentage*100)), str(PhedexSubscription), 100, duplicate, closeOutDataset)
		if closeOutWorkflow:
			phedexSubscription.closeOutWorkflow(url, workflow)
	print '----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------'
def closeOutReRecoWorkflows(url, workflows):
	for workflow in workflows:
		if 'RelVal' in workflow:
			continue
    		if 'TEST' in workflow:
			continue
		datasets=phedexSubscription.outputdatasetsWorkflow(url, workflow)
		closeOutWorkflow=True
		InputDataset=dbsTest.getInputDataSet(url, workflow)
		for dataset in datasets:
			duplicate=False
			closeOutDataset=True
			Percentage=PercentageCompletion(url, workflow, dataset)
			PhedexSubscription=testOutputDataset(dataset)
			closeOutDataset=False
			if Percentage==1 and PhedexSubscription and not duplicate:
				closeOutDataset=True
			else:
         			closeOutDataset=False
			closeOutWorkflow=closeOutWorkflow and closeOutDataset
			print '| %80s | %100s | %4s | %5s| %3s | %5s|%5s| ' % (workflow, dataset,str(int(Percentage*100)), str(PhedexSubscription), 100, duplicate, closeOutDataset)
		if closeOutWorkflow:
			phedexSubscription.closeOutWorkflow(url, workflow)
	print '----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------'