CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
dataset.LocalDataset Class Reference
Inheritance diagram for dataset.LocalDataset:
dataset.BaseDataset

Public Member Functions

def __init__ (self, name, basedir, pattern)
 
def buildListOfFiles (self, pattern='.*root')
 
- Public Member Functions inherited from dataset.BaseDataset
def __init__ (self, name, user, pattern='.*root', run_range=None, dbsInstance=None)
 def init(self, name, user, pattern='. More...
 
def buildListOfBadFiles (self)
 
def buildListOfFiles (self, pattern)
 
def extractFileSizes (self)
 
def getPrimaryDatasetEntries (self)
 
def listOfFiles (self)
 
def listOfGoodFiles (self)
 
def listOfGoodFilesWithPrescale (self, prescale)
 
def printFiles (self, abspath=True, info=True)
 
def printInfo (self)
 

Public Attributes

 basedir
 
 dir
 
 files
 
- Public Attributes inherited from dataset.BaseDataset
 bad_files
 
 dbsInstance
 MM. More...
 
 files
 
 filesAndSizes
 
 good_files
 
 name
 
 pattern
 
 primaryDatasetEntries
 MM. More...
 
 report
 
 run_range
 
 user
 

Detailed Description

Definition at line 233 of file dataset.py.

Constructor & Destructor Documentation

def dataset.LocalDataset.__init__ (   self,
  name,
  basedir,
  pattern 
)

Definition at line 235 of file dataset.py.

235  def __init__(self, name, basedir, pattern):
236  self.basedir = basedir
237  super(LocalDataset, self).__init__( name, 'LOCAL', pattern)
238 
def __init__(self, name, basedir, pattern)
Definition: dataset.py:235

Member Function Documentation

def dataset.LocalDataset.buildListOfFiles (   self,
  pattern = '.*root' 
)

Definition at line 239 of file dataset.py.

239  def buildListOfFiles(self, pattern='.*root'):
240  pat = re.compile( pattern )
241  sampleName = self.name.rstrip('/')
242  self.dir = ''.join( [os.path.abspath(self.basedir),
243  sampleName ] )
244  self.files = []
245  for file in sorted(os.listdir( self.dir )):
246  if pat.match( file ) is not None:
247  self.files.append( '/'.join([self.dir, file]) )
248  # print file
249 
static std::string join(char **cmd)
Definition: RemoteFile.cc:18
def buildListOfFiles(self, pattern='.*root')
Definition: dataset.py:239

Member Data Documentation

dataset.LocalDataset.basedir

Definition at line 236 of file dataset.py.

dataset.LocalDataset.dir

Definition at line 242 of file dataset.py.

dataset.LocalDataset.files

Definition at line 244 of file dataset.py.