File indexing completed on 2025-01-14 02:38:52
0001
0002
0003
0004
0005
0006 import FWCore.ParameterSet.Config as cms
0007 import sys
0008
0009 process = cms.Process("READMERGE")
0010 process.MessageLogger.cerr.FwkReport.reportEvery = 1000
0011 process.MessageLogger.cerr.threshold = cms.untracked.string('ERROR')
0012
0013 process.load("FWCore.Framework.test.cmsExceptionsFatal_cff")
0014
0015 from IOPool.TFileAdaptor.modules import AdaptorConfig
0016 process.add_(AdaptorConfig(stats = False))
0017
0018 process.maxEvents.input = -1
0019
0020 from IOPool.Output.modules import PoolOutputModule
0021 process.output = PoolOutputModule(fileName = 'reduced_test.root')
0022
0023 from FWCore.Framework.modules import TestMergeResults, RunLumiEventAnalyzer
0024 process.testmerge = TestMergeResults(
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035
0036
0037 expectedBeginRunNew = [
0038 10001, 20004, 10003,
0039 10001, 20004, 10003,
0040 10001, 20004, 10003,
0041 10001, 20004, 10003,
0042 10001, 20004, 10003,
0043 10001, 20004, 10003,
0044 10001, 20004, 10003,
0045 10001, 20004, 10003,
0046 10001, 20004, 10003,
0047 10001, 20004, 10003,
0048 10001, 20004, 10003,
0049 10001, 20004, 10003,
0050 10001, 20004, 10003
0051 ],
0052
0053 expectedEndRunNew = [
0054 100001, 200004, 100003,
0055 100001, 200004, 100003,
0056 100001, 200004, 100003,
0057 100001, 200004, 100003,
0058 100001, 200004, 100003,
0059 100001, 200004, 100003,
0060 100001, 200004, 100003,
0061 100001, 200004, 100003,
0062 100001, 200004, 100003,
0063 100001, 200004, 100003,
0064 100001, 200004, 100003,
0065 100001, 200004, 100003,
0066 100001, 200004, 100003
0067 ],
0068
0069 expectedBeginLumiNew = [
0070 101, 204, 103
0071
0072 ],
0073
0074 expectedEndLumiNew = [
0075 1001, 2004, 1003,
0076 ],
0077
0078 expectedProcessHistoryInRuns = [
0079 'PROD',
0080 'MERGE',
0081 'MERGETWOFILES',
0082 'PROD',
0083 'MERGE',
0084 'MERGETWOFILES',
0085 'PROD',
0086 'EXTRA',
0087 'MERGE',
0088 'MERGETWOFILES',
0089 'PROD',
0090 'EXTRA',
0091 'MERGE',
0092 'MERGETWOFILES',
0093 'PROD',
0094 'MERGE',
0095 'MERGETWOFILES',
0096 'PROD',
0097 'MERGE',
0098 'MERGETWOFILES',
0099 'PROD',
0100 'MERGE',
0101 'MERGETWOFILES',
0102 'PROD',
0103 'EXTRA',
0104 'MERGE',
0105 'MERGETWOFILES',
0106 'PROD',
0107 'EXTRA',
0108 'MERGE',
0109 'MERGETWOFILES',
0110 'PROD',
0111 'EXTRA',
0112 'MERGE',
0113 'MERGETWOFILES',
0114 'PROD',
0115 'EXTRA',
0116 'MERGE',
0117 'MERGETWOFILES',
0118 'PROD',
0119 'EXTRA',
0120 'MERGE',
0121 'MERGETWOFILES',
0122 'PROD',
0123 'EXTRA',
0124 'MERGE',
0125 'MERGETWOFILES'
0126 ],
0127 verbose = True
0128 )
0129
0130 from IOPool.Input.modules import PoolSource
0131 process.source = PoolSource(
0132 fileNames = [f"file:{sys.argv[1]}"],
0133 duplicateCheckMode = "noDuplicateCheck"
0134 )
0135
0136 process.test = RunLumiEventAnalyzer(
0137 verbose = True,
0138 expectedRunLumiEvents = [
0139 100, 0, 0,
0140 100, 100, 0,
0141 100, 100, 100,
0142 100, 100, 100,
0143 100, 100, 0,
0144 100, 0, 0,
0145 1, 0, 0,
0146 1, 1, 0,
0147 1, 1, 11,
0148 1, 1, 12,
0149 1, 1, 13,
0150 1, 1, 14,
0151 1, 1, 15,
0152 1, 1, 16,
0153 1, 1, 17,
0154 1, 1, 18,
0155 1, 1, 19,
0156 1, 1, 20,
0157 1, 1, 102,
0158 1, 1, 11,
0159 1, 1, 12,
0160 1, 1, 13,
0161 1, 1, 14,
0162 1, 1, 15,
0163 1, 1, 16,
0164 1, 1, 17,
0165 1, 1, 18,
0166 1, 1, 19,
0167 1, 1, 20,
0168 1, 1, 102,
0169 1, 1, 0,
0170 1, 0, 0,
0171 1, 0, 0,
0172 1, 1, 0,
0173 1, 1, 21,
0174 1, 1, 22,
0175 1, 1, 23,
0176 1, 1, 24,
0177 1, 1, 25,
0178 1, 1, 1,
0179 1, 1, 2,
0180 1, 1, 3,
0181 1, 1, 4,
0182 1, 1, 5,
0183 1, 1, 6,
0184 1, 1, 7,
0185 1, 1, 8,
0186 1, 1, 9,
0187 1, 1, 10,
0188 1, 1, 21,
0189 1, 1, 22,
0190 1, 1, 23,
0191 1, 1, 24,
0192 1, 1, 25,
0193 1, 1, 1,
0194 1, 1, 2,
0195 1, 1, 3,
0196 1, 1, 4,
0197 1, 1, 5,
0198 1, 1, 6,
0199 1, 1, 7,
0200 1, 1, 8,
0201 1, 1, 9,
0202 1, 1, 10,
0203 1, 1, 0,
0204 1, 2, 0,
0205 1, 2, 0,
0206 1, 0, 0,
0207 2, 0, 0,
0208 2, 1, 0,
0209 2, 1, 1,
0210 2, 1, 2,
0211 2, 1, 3,
0212 2, 1, 4,
0213 2, 1, 5,
0214 2, 1, 1,
0215 2, 1, 2,
0216 2, 1, 3,
0217 2, 1, 4,
0218 2, 1, 5,
0219 2, 1, 0,
0220 2, 0, 0
0221 ]
0222 )
0223
0224 process.test.expectedRunLumiEvents.extend([
0225 11, 0, 0,
0226 11, 1, 0,
0227 11, 1, 1,
0228 11, 1, 1,
0229 11, 1, 0,
0230 11, 2, 0,
0231 11, 2, 1,
0232 11, 2, 2,
0233 11, 2, 3,
0234 11, 2, 1,
0235 11, 2, 2,
0236 11, 2, 3,
0237 11, 2, 0,
0238 11, 3, 0,
0239 11, 3, 4,
0240 11, 3, 5,
0241 11, 3, 6,
0242 11, 3, 4,
0243 11, 3, 5,
0244 11, 3, 6,
0245 11, 3, 0,
0246 11, 4, 0,
0247 11, 4, 7,
0248 11, 4, 8,
0249 11, 4, 9,
0250 11, 4, 7,
0251 11, 4, 8,
0252 11, 4, 9,
0253 11, 4, 0,
0254 11, 0, 0,
0255 12, 0, 0,
0256 12, 2, 0,
0257 12, 2, 1,
0258 12, 2, 2,
0259 12, 2, 3,
0260 12, 2, 1,
0261 12, 2, 2,
0262 12, 2, 3,
0263 12, 2, 0,
0264 12, 3, 0,
0265 12, 3, 4,
0266 12, 3, 5,
0267 12, 3, 6,
0268 12, 3, 4,
0269 12, 3, 5,
0270 12, 3, 6,
0271 12, 3, 0,
0272 12, 4, 0,
0273 12, 4, 7,
0274 12, 4, 8,
0275 12, 4, 9,
0276 12, 4, 7,
0277 12, 4, 8,
0278 12, 4, 9,
0279 12, 4, 0,
0280 12, 0, 0,
0281 13, 0, 0,
0282 13, 2, 0,
0283 13, 2, 1,
0284 13, 2, 2,
0285 13, 2, 1,
0286 13, 2, 2,
0287 13, 2, 0,
0288 13, 0, 0,
0289 1000, 0, 0,
0290 1000, 1, 0,
0291 1000, 1, 0,
0292 1000, 0, 0,
0293 1001, 0, 0,
0294 1001, 1, 0,
0295 1001, 1, 0,
0296 1001, 0, 0,
0297 1002, 0, 0,
0298 1002, 1, 0,
0299 1002, 1, 0,
0300 1002, 0, 0,
0301
0302
0303
0304 2000, 0, 0,
0305 2000, 0, 0,
0306 2001, 0, 0,
0307 2001, 0, 0,
0308 2002, 0, 0,
0309 2002, 0, 0
0310 ])
0311
0312 process.path1 = cms.EndPath(process.test*process.testmerge)
0313
0314 process.ep = cms.EndPath(process.output)