예제 #1
0
##       print "i:", particles
##       print particleCharge
      ## print "Jet - ", fjet
       # print "Nr of jets=", fjet.njets()  
       alljets=[] # make a new list with jets 
#       print "# of jets ", fjet.njets()
       for i in range(fjet.njets()):
		 # print "Jet=",i," Nr if particles in jet =",fjet.nParticlesPerJet(i) 
         pjet=fjet.jet(i)   # make  HepLorentzVector
###         print fjet.particlesInJet(i)
###         print "jet", pjet
         ee=pjet.t()  # energy
         p3=pjet.v3() # 3-vector  
         #print " ",ee,p3
         pl_uncut=LParticle(p3.x(),p3.y(),p3.z(),ee)
         hjetpT_uncut.fill(pl_uncut.perp())
#================MAW===========================================================
         JetIds = [] #storing the PID of particles in the jet
         JETset=[] #converting fjet into LParticle array
         for j in range(fjet.nParticlesPerJet(i)):   
            for s in range(len(particleCharge)):
               if (fjet.particlesInJet(i)[j] == particles[s]):
                  particles.remove(particles[s])
                  CHARGE=particleCharge[s]
                  particleCharge.pop(s)
                  pid_j =  PDGlist[s]
                  PDGlist.pop(s)
                  if (CHARGE != 0.0):
                     njettracks_uncut=njettracks_uncut+1
                  break
            JetIds.append(pid_j)