CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_2_9/src/DQM/HcalMonitorModule/python/inputfiles.py

Go to the documentation of this file.
00001 rootfiles=[
00002     # Collisions at 900 GeV
00003     # /ExpressPhysics/BeamCommissioning09-Express-v2/FEVT  ---  run = 124022 and lumi>35 and lumi<100 #
00004     '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/FC89901D-FFE6-DE11-AA38-001D09F25401.root',
00005     '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/FC0FBE28-FAE6-DE11-9C39-0030487A3232.root',
00006     '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/FA34E8C3-F8E6-DE11-8690-000423D99F1E.root',
00007     '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/F411ED8A-00E7-DE11-ADD6-001D09F24259.root',
00008     '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/EED37FD3-FFE6-DE11-A920-001D09F27003.root',
00009     '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/EA8BC9C3-F8E6-DE11-B5E7-000423D98BC4.root',
00010         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/DEFC94D2-FFE6-DE11-8C5D-001D09F29597.root',
00011         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/DAE9A81C-FFE6-DE11-A9C0-001D09F290CE.root',
00012         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/D61F55D4-FFE6-DE11-8F08-001D09F24763.root',
00013         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/D4E246DB-FAE6-DE11-B1EC-001D09F244BB.root',
00014         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/CCF8E65B-FEE6-DE11-9C60-001D09F2915A.root',
00015         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/CC426156-F9E6-DE11-BC44-000423D9890C.root',
00016         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/CC2FEB24-FAE6-DE11-AF03-0019DB29C614.root',
00017         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/BE88DA89-00E7-DE11-8AFB-001D09F290BF.root',
00018         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/B6B98DB0-FDE6-DE11-B68A-000423D98EA8.root',
00019         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/B4A63547-FCE6-DE11-BC18-001D09F29321.root',
00020         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/AC966147-FCE6-DE11-9B12-0019B9F730D2.root',
00021         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/A8D5D1FA-FCE6-DE11-8104-000423D9890C.root',
00022         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/A85FA1C3-F8E6-DE11-9426-000423D9A212.root',
00023         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/A4DD025B-FEE6-DE11-AAD0-001D09F24F1F.root',
00024         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/A414A5FB-FCE6-DE11-86FC-001617E30D12.root',
00025         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/9C9305B0-FDE6-DE11-B7FE-001D09F24259.root',
00026         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/982ACE88-00E7-DE11-A8BC-001D09F24D8A.root',
00027         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/94777646-FCE6-DE11-AEFD-001D09F24FBA.root',
00028         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/846EAA3F-01E7-DE11-8AE4-0030487D0D3A.root',
00029         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/749CEAFE-FCE6-DE11-B341-001617DBCF6A.root',
00030         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/6A72D340-01E7-DE11-A1AF-0030487D1BCC.root',
00031         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/66BC1FB2-FDE6-DE11-806D-000423D952C0.root',
00032         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/5ACD66B1-FDE6-DE11-A8DD-001D09F27003.root',
00033         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/5A7DD1F6-FCE6-DE11-BD0F-000423D9997E.root',
00034         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/5432D247-FCE6-DE11-87FD-001D09F2516D.root',
00035         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/46FAE4DB-FAE6-DE11-9152-001D09F24303.root',
00036         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/421BA7B3-FDE6-DE11-9931-001D09F24353.root',
00037         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/2C32DCC3-F8E6-DE11-B256-000423D33970.root',
00038         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/2AB9A18A-FBE6-DE11-8759-001617E30F50.root',
00039         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/285060B2-FDE6-DE11-9DA2-001D09F2AF96.root',
00040         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/24DB2A8B-FBE6-DE11-AA05-000423D98EC8.root',
00041         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/22AAB44C-F7E6-DE11-91B4-001D09F2906A.root',
00042         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/22A5551C-FFE6-DE11-B7C3-001D09F25393.root',
00043         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/1A563723-FAE6-DE11-9887-000423D60FF6.root',
00044         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/167E685B-FEE6-DE11-8E02-0019B9F72F97.root',
00045         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/0CDBF14E-F7E6-DE11-B9E1-001D09F26509.root',
00046         '/store/express/BeamCommissioning09/ExpressPhysics/FEVT/v2/000/124/022/06B52B97-FBE6-DE11-A989-001617E30E28.root'
00047     ]
00048 
00049 
00050 datfiles=[
00051 'file:/tmp/temple/inputfiles/Data.00128766.0001.A.storageManager.00.0000.dat',
00052 'file:/tmp/temple/inputfiles/Data.00128766.0021.A.storageManager.01.0000.dat',
00053 'file:/tmp/temple/inputfiles/Data.00128766.0041.A.storageManager.02.0000.dat',
00054 'file:/tmp/temple/inputfiles/Data.00128766.0061.A.storageManager.03.0000.dat',
00055 'file:/tmp/temple/inputfiles/Data.00128766.0081.A.storageManager.04.0000.dat',
00056 'file:/tmp/temple/inputfiles/Data.00128766.0101.A.storageManager.05.0000.dat',
00057 'file:/tmp/temple/inputfiles/Data.00128766.0121.A.storageManager.06.0000.dat',
00058 'file:/tmp/temple/inputfiles/Data.00128766.0141.A.storageManager.07.0000.dat',
00059 'file:/tmp/temple/inputfiles/Data.00128766.0161.A.storageManager.08.0000.dat',
00060 'file:/tmp/temple/inputfiles/Data.00128766.0181.A.storageManager.09.0000.dat',
00061 'file:/tmp/temple/inputfiles/Data.00128766.0201.A.storageManager.10.0000.dat',
00062 'file:/tmp/temple/inputfiles/Data.00128766.0221.A.storageManager.11.0000.dat',
00063 'file:/tmp/temple/inputfiles/Data.00128766.0241.A.storageManager.12.0000.dat',
00064 'file:/tmp/temple/inputfiles/Data.00128766.0261.A.storageManager.13.0000.dat',
00065 'file:/tmp/temple/inputfiles/Data.00128766.0281.A.storageManager.14.0000.dat',
00066     ]
00067 
00068 def copyfiles(filelist,args=None):
00069     import string
00070     import os
00071     dir="/tmp/temple/inputfiles"
00072     if len(args)>0:
00073         dir=args[0]
00074     if not os.path.isdir(dir):
00075         print "Sorry, dir '%s' does not exist"%dir
00076         return
00077     startcount=-1
00078     endcount=9999999999
00079     if (len(args)>1):
00080         startcount=string.atoi(args[1])
00081     if (len(args)>2):
00082         endcount=string.atoi(args[2])
00083 
00084     print "startcount = ",startcount
00085     print "endcount = ",endcount
00086     counter=0
00087     for i in filelist:
00088         if not i.startswith("/store/"):
00089             continue
00090         counter=counter+1
00091         if (counter<startcount):
00092             continue
00093         temp=string.replace(i,"/store/","/castor/cern.ch/cms/store/")
00094         cmd="rfcp %s /tmp/temple/inputfiles"%temp
00095         print cmd
00096         os.system(cmd)
00097         if (counter>=endcount):
00098             break
00099 
00100 def makelocal(filelist,dir):
00101     import string
00102     import os
00103     
00104     newfilelist=[]
00105     for i in range(len(filelist)):
00106         temp=os.path.basename(filelist[i])
00107         temp=os.path.join(dir,temp)
00108         if os.path.isfile(temp):
00109             newfilelist.append("file:%s"%temp)
00110     return newfilelist
00111 
00112 if __name__=="__main__":
00113     import string
00114     import os
00115     import sys
00116     outdir="/tmp/temple/inputfiles/"
00117     if len(sys.argv)>1:
00118         outdir=sys.argv[1]
00119     if not os.path.isdir(outdir):
00120         print "Sorry, output directory '%s' does not exist!"%outdir
00121     copyfiles(rootfiles,sys.argv[1:])