Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-09-26 05:06:39

0001 #!/bin/bash
0002 
0003 function die { echo $1: status $2 ;  exit $2; }
0004 
0005 LOCAL_TEST_DIR=${SCRAM_TEST_PATH}
0006 
0007 cmsRun ${LOCAL_TEST_DIR}/create_Run2Scouting_test_file_cfg.py || die 'Failure using create_Run2Scouting_test_file_cfg.py' $?
0008 
0009 cmsRun ${LOCAL_TEST_DIR}/test_readRun2Scouting_cfg.py || die "Failure using test_readRun2Scouting_cfg.py" $?
0010 
0011 # The old files read below were generated as follows.
0012 #
0013 #     testRun2Scouting_v3_v2_v2_v3_v2_v2_v2_CMSSW_8_0_7_split_99.root:
0014 #     Check out the 8_0_7 release and cherry pick the commit that
0015 #     adds the original version of the file
0016 #     DataFormats/Scouting/test/TestWriteRun2Scouting.cc
0017 #     (6 files added by that commit). There likely will be
0018 #     minor conflicts or issues in test/BuildFile.xml that need to
0019 #     be resolved.
0020 #
0021 #     testRun2Scouting_v3_v2_v3_v3_v2_v2_v3_CMSSW_9_4_0_split_99.root
0022 #     Check out the 9_4_0 release and cherry pick the commit that
0023 #     adds the original version of the file
0024 #     DataFormats/Scouting/test/TestWriteRun2Scouting.cc.
0025 #     Also check out the second commit that modifies that file.
0026 #     (6 files added by those commits). There likely will be
0027 #     minor conflicts or issues in test/BuildFile.xml that need to
0028 #     be resolved.
0029 #
0030 #     testRun2Scouting_v3_v2_v3_v3_v2_v2_v2_v3_CMSSW_10_2_0_split_99.root
0031 #     Check out the 10_2_0 release and cherry pick the commit that
0032 #     adds the original version of the file
0033 #     DataFormats/Scouting/test/TestWriteRun2Scouting.cc.
0034 #     Also check out the second and third commits that modify that file.
0035 #     (6 files added by those commits). There likely will be
0036 #     minor conflicts or issues in test/BuildFile.xml that need to
0037 #     be resolved.
0038 #
0039 # Run the create_Run2Scouting_test_file_cfg.py configuration and
0040 # rename the file it creates.
0041 #
0042 # The versions of the classes are encoded in the filenames in
0043 # alphabetical order. This order is also the order the Run 2
0044 # Scouting classes appear in classes_def.xml (in the master branch
0045 # of CMSSW).
0046 #
0047 # By default, split level 99 is used (maximum possible splitting).
0048 # If the suffix "_split_0" is near the end of the filename, the
0049 # following was added to the configuration of the output module:
0050 #     "splitLevel = cms.untracked.int32(0)"
0051 #
0052 # The versions that changed from 8_0_7 to 9_4_0 were the versions of
0053 # the ScoutingMuon and ScoutingVertex classes. The change in the
0054 # 10_2_0 was the addition of the ScoutingTrack class.
0055 #
0056 # 8_0_7 was chosen because the 8_0_X release cycle was used
0057 # for 2016 data, and the scouting data formats were not updated
0058 # after 8_0_7.
0059 #
0060 # 9_4_0 was chosen because the 9_4_X release cycle was used
0061 # for 2017 data, and the scouting data formats were not updated
0062 # after 9_4_0.
0063 #
0064 # 10_2_0 was chosen because the 10_2_X release cycle was used
0065 # for 2018 data, and the scouting data formats were not updated
0066 # after 10_2_0.
0067 
0068 oldFiles="testRun2Scouting_v3_v2_v2_v3_v2_v2_v2_CMSSW_8_0_7_split_99.root testRun2Scouting_v3_v2_v2_v3_v2_v2_v2_CMSSW_8_0_7_split_0.root"
0069 for file in $oldFiles; do
0070   inputfile=$(edmFileInPath DataFormats/Scouting/data/$file) || die "Failure edmFileInPath DataFormats/Scouting/data/$file" $?
0071   argsPassedToPython="--inputFile $inputfile --outputFileName testRun2Scouting2_CMSSW_8_0_7.root --muonVersion 2 --trackVersion 0 --vertexVersion 2"
0072   cmsRun ${LOCAL_TEST_DIR}/test_readRun2Scouting_cfg.py $argsPassedToPython || die "Failed to read old file $file" $?
0073 done
0074 
0075 oldFiles="testRun2Scouting_v3_v2_v3_v3_v2_v2_v3_CMSSW_9_4_0_split_99.root testRun2Scouting_v3_v2_v3_v3_v2_v2_v3_CMSSW_9_4_0_split_0.root"
0076 for file in $oldFiles; do
0077   inputfile=$(edmFileInPath DataFormats/Scouting/data/$file) || die "Failure edmFileInPath DataFormats/Scouting/data/$file" $?
0078   argsPassedToPython="--inputFile $inputfile --outputFileName testRun2Scouting2_CMSSW_9_4_0.root --muonVersion 3 --trackVersion 0 --vertexVersion 3"
0079   cmsRun ${LOCAL_TEST_DIR}/test_readRun2Scouting_cfg.py  $argsPassedToPython || die "Failed to read old file $file" $?
0080 done
0081 
0082 oldFiles="testRun2Scouting_v3_v2_v3_v3_v2_v2_v2_v3_CMSSW_10_2_0_split_99.root testRun2Scouting_v3_v2_v3_v3_v2_v2_v2_v3_CMSSW_10_2_0_split_0.root"
0083 for file in $oldFiles; do
0084   inputfile=$(edmFileInPath DataFormats/Scouting/data/$file) || die "Failure edmFileInPath DataFormats/Scouting/data/$file" $?
0085   argsPassedToPython="--inputFile $inputfile --outputFileName testRun2Scouting2_CMSSW_10_2_0.root --muonVersion 3 --trackVersion 2 --vertexVersion 3"
0086   cmsRun ${LOCAL_TEST_DIR}/test_readRun2Scouting_cfg.py $argsPassedToPython || die "Failed to read old file $file" $?
0087 done
0088 
0089 exit 0