# TAG
EventSelector.Query="MissingET>20000&&NLooseElectron>=2"
EventSelector.CollectionType="ExplicitROOT"
DetDescrVersion="ATLAS-CSC-01-01-00"
readAOD = True
doWriteAOD = True
# read the TAG as input to the job
readColl = True
# define also the selection criteria
CollInputQuery="MissingET>20000 && NLooseMuon>1"
#Create a new RDO, ESD and AOD that contain only selected events
PoolAODOutput = "myselectedfiles.recon.AOD.TagSel.root"
# main reconstruction job jobOptions
include ("RecExCommon/RecExCommon_topOptions.py")
...
j = Job()
j.name='myjob'
j.application=Athena()
j.application.prepare(athena_compile=False)
j.application.option_file='$HOME/some_directory/some_joboption.py'
j.inputdata=DQ2Dataset()
j.inputdata.dataset='some_input.merge.AOD'
j.inputdata.tagdataset='some_input.merge.TAG'
j.inputdata.type='TAG'
j.outputdata=DQ2OutputDataset()
j.outputdata.outputdata=['AnalysisSkeleton.aan.root']
j.backend=LCG()
j.submit()
def execute(self):
nele=0
goodele = []
ec = PyParticleTools.getElectrons("ElectronAODCollection")
for i in range(ec.size()) :
if ec[i].author(1) :
if ec[i].isem(0xff)==0:
if ec[i].pt()>10000 and abs(ec[i].eta())<2.5:
nele+=1
goodele += [i]
#Keep events with egamma Loose electrons
#Events Skimming
if nele>1:
self.setFilterPassed(True)
else:
self.setFilterPassed(False)
--
PatrickJussel - 19 Nov 2007