diff --git a/PhysicsAnalysis/DerivationFramework/DerivationFrameworkJetEtMiss/share/LUT_mc12.root b/PhysicsAnalysis/DerivationFramework/DerivationFrameworkJetEtMiss/share/LUT_mc12.root old mode 100755 new mode 100644 diff --git a/Tools/DirectIOART/generateARTtests.py b/Tools/DirectIOART/generateARTtests.py index 531d75d3c91f52e1e14920d6985e3ccdb66ecb8b..ff9527c59cceb1c4a7086d88508d1e425daf08fc 100755 --- a/Tools/DirectIOART/generateARTtests.py +++ b/Tools/DirectIOART/generateARTtests.py @@ -5,9 +5,6 @@ import os HAMMERCLOUD_FILE = "mc15_13TeV.423202.Pythia8B_A14_CTEQ6L1_Jpsie3e13.merge.AOD.e3869_s2608_s2183_r6630_r6264" PROJECTS = ["AthAnalysis", "AthDerivation", "AthSimulation", "Athena", "AnalysisBase"] -#PWD = os.environ['PWD'] -#DIRNAME = "test" - TFILE_OPEN_TURLs = [ {"ROOT": ("root://lcg-lrz-rootd.grid.lrz.de:1094/pnfs/lrz-muenchen.de/data/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1", # LRZ-LMU @@ -44,53 +41,8 @@ TFILE_OPEN_TURLs = [ }, ] -#def writeTFileOpen(athena_project): - #name = os.path.join("test", "test_DirectIO" + athena_project + "ART_TFileOpen.py") - #print "\tGenerating ...",name - #outfile = open(name,'w') - - ## generate frame of test scripts - #outstring = """#!/usr/bin/env python\n -## art-description: DirectIO{project}ART TFile::Open -## art-type: grid -## art-include: {branch}/{project}\n -#import ROOT -#import os\n""".format(project=athena_project, branch='21.0' if athena_project == 'Athena' else '21.3' if athena_project == 'AthSimulation' else '21.2') - ## loop over turl list - #for i in xrange(len(TFILE_OPEN_TURLs)): - ## get values of dictionaries - #for key, value in TFILE_OPEN_TURLs[i].items(): - ## add turl to filenames string - #filenames = "" - #for j in xrange(len(value)): - #filenames += value[j] - #if j < len(value)-1: filenames += " | " - #outstring += """ -#f = ROOT.TFile.Open(\"{turl}\") -#n = f.GetName() -#if f: print(\"art-result: 0 DirectIO{project}ART_TFileOpen_protocol_{protocol}\") -#else: print(\"art-result: 1 DirectIO{project}ART_TFileOpen_protocol_{protocol}\") -#del f -#os.system(\"pool_insertFileToCatalog {{}}\".format(n))\n""".format(turl=filenames, project=athena_project, protocol=key) - #filenames = "" - - ## back to main test scripts - #outfile.write(outstring) - #outfile.close() - #os.system("chmod +x " + name) - -#def parse_options(): - #import argparse - #parser = argparse.ArgumentParser() - - #parser.add_argument("athena_project", help="Specify the Athena release flavour (Default=AthAnalysis)", type=str, nargs="*" ) - #parser.add_argument("-o", "--tfile-open", help="Generate ART scripts for TFile::Open tests", action="store_true", dest="open_tests") - - #options = parser.parse_args() - #return options - def writeTFileOpen(): - name = os.path.join("test", "test_DirectIOART_TFileOpen.py") + name = os.path.join("test", "test_directioart_tfileopen.py") print "\tGenerating ...",name outfile = open(name,'w') @@ -111,14 +63,22 @@ import os\n""" if j < len(value)-1: filenames += " | " outstring += """ f = ROOT.TFile.Open(\"{turl}\") -n = f.GetName() if f: print(\"art-result: 0 DirectIOART_TFileOpen_protocol_{protocol}\") else: print(\"art-result: 1 DirectIOART_TFileOpen_protocol_{protocol}\") -del f -os.system(\"pool_insertFileToCatalog {{}}\".format(n))\n""".format(turl=filenames, protocol=key) +del f\n""".format(turl=filenames, protocol=key) filenames = "" # back to main test scripts + outstring += """ +outstr = \"\"\"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\" ?> +<!-- Edited By POOL --> +<!DOCTYPE POOLFILECATALOG SYSTEM \"InMemory\"> +<POOLFILECATALOG> + +</POOLFILECATALOG>\"\"\" +with open(\"PoolFileCatalog.xml\", \"w\") as outfile: + outfile.write(outstr)""" + outfile.write(outstring) outfile.close() os.system("chmod +x " + name) @@ -145,10 +105,7 @@ def main(): if not opts.athena_project[i] in PROJECTS: print "\tAthena project \"",opts.athena_project[i],"\" not intended for DirectIOART!" continue - - #if opts.open_tests: - #writeTFileOpen(opts.athena_project[i]) - + if opts.open_tests: writeTFileOpen() diff --git a/Tools/DirectIOART/test/test_DirectIOART_TFileOpen.py b/Tools/DirectIOART/test/test_directioart_tfileopen.py similarity index 93% rename from Tools/DirectIOART/test/test_DirectIOART_TFileOpen.py rename to Tools/DirectIOART/test/test_directioart_tfileopen.py index e640e380818fc57baea48ed6422b5124640da4ae..982d4bc4dfcec167e00bfd49e7e2d684b4deb31f 100755 --- a/Tools/DirectIOART/test/test_DirectIOART_TFileOpen.py +++ b/Tools/DirectIOART/test/test_directioart_tfileopen.py @@ -7,22 +7,25 @@ import ROOT import os f = ROOT.TFile.Open("root://lcg-lrz-rootd.grid.lrz.de:1094/pnfs/lrz-muenchen.de/data/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://grid-dc.rzg.mpg.de:1094//pnfs/rzg.mpg.de/data/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://dcache-atlas-xrootd.desy.de:1094//pnfs/desy.de/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://lcg-se0.ifh.de:1094//pnfs/ifh.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://atlasxrootd-kit.gridka.de:1094//pnfs/gridka.de/atlas/disk-only/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://sedoor1.bfg.uni-freiburg.de:1094//pnfs/bfg.uni-freiburg.de/data/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://se-goegrid.gwdg.de:1094//pnfs/gwdg.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | root://grid-se.physik.uni-wuppertal.de:1094//pnfs/physik.uni-wuppertal.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1") -n = f.GetName() if f: print("art-result: 0 DirectIOART_TFileOpen_protocol_ROOT") else: print("art-result: 1 DirectIOART_TFileOpen_protocol_ROOT") del f -os.system("pool_insertFileToCatalog {}".format(n)) f = ROOT.TFile.Open("davs://lcg-lrz-http.grid.lrz.de:443/pnfs/lrz-muenchen.de/data/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://grid-dav.rzg.mpg.de:2880/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://dcache-atlas-webdav.desy.de:2880/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://lcg-se0.ifh.de:2880/pnfs/ifh.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://atlaswebdav-kit.gridka.de:2880/pnfs/gridka.de/atlas/disk-only/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://webdav.bfg.uni-freiburg.de:2880/pnfs/bfg.uni-freiburg.de/data/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://se-goegrid.gwdg.de:2880/pnfs/gwdg.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | davs://grid-se.physik.uni-wuppertal.de:2881/pnfs/physik.uni-wuppertal.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1") -n = f.GetName() if f: print("art-result: 0 DirectIOART_TFileOpen_protocol_DAVS") else: print("art-result: 1 DirectIOART_TFileOpen_protocol_DAVS") del f -os.system("pool_insertFileToCatalog {}".format(n)) f = ROOT.TFile.Open("https://lcg-lrz-http.grid.lrz.de:443/pnfs/lrz-muenchen.de/data/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https://grid-dav.rzg.mpg.de:2880/atlas/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https://dcache-atlas-webdav.desy.de:2880/dq2/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https://lcg-se0.ifh.de:2880/pnfs/ifh.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https ://atlaswebdav-kit.gridka.de:2880/pnfs/gridka.de/atlas/disk-only/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https://webdav.bfg.uni-freiburg.de:2880/pnfs/bfg.uni-freiburg.de/data/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https://se-goegrid.gwdg.de:2880/pnfs/gwdg.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1 | https://grid-se.physik.uni-wuppertal.de:2881/pnfs/physik.uni-wuppertal.de/data/atlas/atlasdatadisk/rucio/mc15_13TeV/ed/68/AOD.05536542._000001.pool.root.1") -n = f.GetName() if f: print("art-result: 0 DirectIOART_TFileOpen_protocol_HTTPS") else: print("art-result: 1 DirectIOART_TFileOpen_protocol_HTTPS") del f -os.system("pool_insertFileToCatalog {}".format(n)) + +outstr = """<?xml version="1.0" encoding="UTF-8" standalone="no" ?> +<!-- Edited By POOL --> +<!DOCTYPE POOLFILECATALOG SYSTEM "InMemory"> +<POOLFILECATALOG> + +</POOLFILECATALOG>""" +with open("PoolFileCatalog.xml", "w") as outfile: + outfile.write(outstr) \ No newline at end of file