Definition at line 14 of file dataset.py.
def dataset.Dataset.__init__ |
( |
|
self, |
|
|
|
datasetName, |
|
|
|
dasLimit = 0 , |
|
|
|
tryPredefinedFirst = True , |
|
|
|
cmssw = os.environ["CMSSW_BASE"] , |
|
|
|
cmsswrelease = os.environ["CMSSW_RELEASE_BASE"] |
|
) |
| |
def dataset.Dataset.__init__ |
( |
|
self, |
|
|
|
name, |
|
|
|
user, |
|
|
|
pattern = '.*root' |
|
) |
| |
def dataset.Dataset.__chunks |
( |
|
self, |
|
|
|
theList, |
|
|
|
n |
|
) |
| |
|
private |
Yield successive n-sized chunks from theList.
Definition at line 79 of file dataset.py.
def dataset.Dataset.__createSnippet |
( |
|
self, |
|
|
|
jsonPath = None , |
|
|
|
begin = None , |
|
|
|
end = None , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None , |
|
|
|
repMap = None , |
|
|
|
crab = False , |
|
|
|
parent = False |
|
) |
| |
|
private |
def dataset.Dataset.__dateString |
( |
|
self, |
|
|
|
date |
|
) |
| |
|
private |
def dataset.Dataset.__datetime |
( |
|
self, |
|
|
|
stringForDas |
|
) |
| |
|
private |
def dataset.Dataset.__fileListSnippet |
( |
|
self, |
|
|
|
crab = False , |
|
|
|
parent = False , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None , |
|
|
|
forcerunselection = False |
|
) |
| |
|
private |
def dataset.Dataset.__find_ge |
( |
|
self, |
|
|
|
a, |
|
|
|
x |
|
) |
| |
|
private |
def dataset.Dataset.__find_lt |
( |
|
self, |
|
|
|
a, |
|
|
|
x |
|
) |
| |
|
private |
def dataset.Dataset.__findInJson |
( |
|
self, |
|
|
|
jsondict, |
|
|
|
strings |
|
) |
| |
|
private |
def dataset.Dataset.__getData |
( |
|
self, |
|
|
|
dasQuery, |
|
|
|
dasLimit = 0 |
|
) |
| |
|
private |
def dataset.Dataset.__getDataType |
( |
|
self | ) |
|
|
private |
def dataset.Dataset.__getFileInfoList |
( |
|
self, |
|
|
|
dasLimit, |
|
|
|
parent = False |
|
) |
| |
|
private |
def dataset.Dataset.__getMagneticField |
( |
|
self | ) |
|
|
private |
def dataset.Dataset.__getMagneticFieldForRun |
( |
|
self, |
|
|
|
run = -1 , |
|
|
|
tolerance = 0.5 |
|
) |
| |
|
private |
For MC, this returns the same as the previous function.
For data, it gets the magnetic field from the runs. This is important for
deciding which template to use for offlinevalidation
Definition at line 479 of file dataset.py.
def dataset.Dataset.__getParentDataset |
( |
|
self | ) |
|
|
private |
def dataset.Dataset.__getRunList |
( |
|
self | ) |
|
|
private |
def dataset.Dataset.__lumiSelectionSnippet |
( |
|
self, |
|
|
|
jsonPath = None , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None |
|
) |
| |
|
private |
def dataset.Dataset.buildListOfBadFiles |
( |
|
self | ) |
|
fills the list of bad files from the IntegrityCheck log.
When the integrity check file is not available,
files are considered as good.
Definition at line 275 of file dataset.py.
def dataset.Dataset.buildListOfFiles |
( |
|
self, |
|
|
|
pattern = '.*root' |
|
) |
| |
fills list of files, taking all root files matching the pattern in the castor dir
Definition at line 271 of file dataset.py.
def dataset.Dataset.convertTimeToRun |
( |
|
self, |
|
|
|
begin = None , |
|
|
|
end = None , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None , |
|
|
|
shortTuple = True |
|
) |
| |
def dataset.Dataset.createdatasetfile_hippy |
( |
|
self, |
|
|
|
filename, |
|
|
|
filesperjob, |
|
|
|
firstrun, |
|
|
|
lastrun |
|
) |
| |
def dataset.Dataset.datasetSnippet |
( |
|
self, |
|
|
|
jsonPath = None , |
|
|
|
begin = None , |
|
|
|
end = None , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None , |
|
|
|
crab = False , |
|
|
|
parent = False |
|
) |
| |
def dataset.Dataset.dataType |
( |
|
self | ) |
|
def dataset.Dataset.dump_cff |
( |
|
self, |
|
|
|
outName = None , |
|
|
|
jsonPath = None , |
|
|
|
begin = None , |
|
|
|
end = None , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None , |
|
|
|
parent = False |
|
) |
| |
def dataset.Dataset.extractFileSizes |
( |
|
self | ) |
|
Get the file size for each file, from the eos ls -l command.
Definition at line 306 of file dataset.py.
def dataset.Dataset.fileInfoList |
( |
|
self, |
|
|
|
parent = False |
|
) |
| |
def dataset.Dataset.fileList |
( |
|
self, |
|
|
|
parent = False , |
|
|
|
firstRun = None , |
|
|
|
lastRun = None , |
|
|
|
forcerunselection = False |
|
) |
| |
def dataset.Dataset.forcerunrange |
( |
|
self, |
|
|
|
firstRun, |
|
|
|
lastRun, |
|
|
|
s |
|
) |
| |
s must be in the format run1:lum1-run2:lum2
Definition at line 311 of file dataset.py.
def dataset.Dataset.getForceRunRangeFunction |
( |
|
self, |
|
|
|
firstRun, |
|
|
|
lastRun |
|
) |
| |
def dataset.Dataset.getPrimaryDatasetEntries |
( |
|
self | ) |
|
def dataset.Dataset.getrunnumberfromfilename |
( |
|
filename | ) |
|
|
static |
def dataset.Dataset.magneticField |
( |
|
self | ) |
|
def dataset.Dataset.magneticFieldForRun |
( |
|
self, |
|
|
|
run = -1 |
|
) |
| |
def dataset.Dataset.name |
( |
|
self | ) |
|
def dataset.Dataset.parentDataset |
( |
|
self | ) |
|
def dataset.Dataset.predefined |
( |
|
self | ) |
|
def dataset.Dataset.printInfo |
( |
|
self | ) |
|
def dataset.Dataset.runList |
( |
|
self | ) |
|
dataset.Dataset.__alreadyStored |
|
private |
dataset.Dataset.__cmsswrelease |
|
private |
dataset.Dataset.__dasLimit |
|
private |
dataset.Dataset.__dataType |
|
private |
tuple dataset.Dataset.__dummy_source_template |
|
staticprivate |
Initial value: 1 = (
"readFiles = cms.untracked.vstring()\n"
2 "secFiles = cms.untracked.vstring()\n"
3 "%(process)ssource = cms.Source(\"PoolSource\",\n"
4 "%(tab)s secondaryFileNames ="
6 "%(tab)s fileNames = readFiles\n"
8 "readFiles.extend(['dummy_File.root'])\n"
9 "%(process)smaxEvents = cms.untracked.PSet( "
10 "input = cms.untracked.int32(%(nEvents)s) )\n"
11 "%(skipEventsString)s\n")
Definition at line 103 of file dataset.py.
dataset.Dataset.__fileInfoList |
|
private |
dataset.Dataset.__fileList |
|
private |
dataset.Dataset.__filename |
|
private |
dataset.Dataset.__firstusedrun |
|
private |
dataset.Dataset.__lastusedrun |
|
private |
dataset.Dataset.__magneticField |
|
private |
dataset.Dataset.__official |
|
private |
dataset.Dataset.__origName |
|
private |
dataset.Dataset.__parentDataset |
|
private |
dataset.Dataset.__parentFileInfoList |
|
private |
dataset.Dataset.__parentFileList |
|
private |
dataset.Dataset.__predefined |
|
private |
dataset.Dataset.__runList |
|
private |
dataset.Dataset.bad_files |
dataset.Dataset.castorDir |
tuple dataset.Dataset.dasData = das_client.get_data(dasQuery, dasLimit) |
|
static |
tuple dataset.Dataset.error = self.__findInJson(jsondict,["data","error"]) |
|
static |
dataset.Dataset.error = None |
|
static |
dataset.Dataset.filesAndSizes |
dataset.Dataset.good_files |
int dataset.Dataset.i = 0 |
|
static |
tuple dataset.Dataset.jsondict = json.loads( dasData ) |
|
static |
string dataset.Dataset.jsonfile = "das_query_output_%i.txt" |
|
static |
dataset.Dataset.jsonfile = jsonfile%i |
|
static |
tuple dataset.Dataset.jsonstr = self.__findInJson(jsondict,"reason") |
|
static |
dataset.Dataset.maskExists |
string dataset.Dataset.msg = "The DAS query returned an error. The output is very long, and has been stored in:\n" |
|
static |
tuple dataset.Dataset.theFile = open( jsonfile, "w" ) |
|
static |