Skip to content

Commit

Permalink
set num events
Browse files Browse the repository at this point in the history
  • Loading branch information
kpedro88 committed Jan 7, 2019
1 parent 81f1fcd commit ce7a6d1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
5 changes: 1 addition & 4 deletions AnalysisFW/python/jetImageTest_mc_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
process.GlobalTag.globaltag = cms.string('100X_upgrade2018_realistic_v10')

process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(10) )
process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(options.maxEvents) )
process.source = cms.Source("PoolSource",
fileNames = cms.untracked.vstring('file:store_mc_RunIISpring18MiniAOD_BulkGravTohhTohbbhbb_narrow_M-2000_13TeV-madgraph_MINIAODSIM_100X_upgrade2018_realistic_v10-v1_30000_24A0230C-B530-E811-ADE3-14187741120B.root')
)
Expand Down Expand Up @@ -63,9 +63,6 @@
process.jetImageProducer
)

# Change number of events here:
process.maxEvents.input = 25

process.MessageLogger.cerr.FwkReport.reportEvery = 1
keep_msgs = ['JetImageProducer','TFClientRemote','TFClientLocal']
for msg in keep_msgs:
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ This script creates a JSON file with the address and port for the remote server,
Now, the producer can run in either local or remote mode.
* Local mode:
```
cmsRun jetImageTest_mc_cfg.py
cmsRun jetImageTest_mc_cfg.py maxEvents=25
```
* Remote mode:
```
cmsRun jetImageTest_mc_cfg.py remote=1 params=$CMSSW_BASE/src/SonicCMS/AnalysisFW/python/service_model_params.json
cmsRun jetImageTest_mc_cfg.py remote=1 params=$CMSSW_BASE/src/SonicCMS/AnalysisFW/python/service_model_params.json maxEvents=25
```

The remote mode timeout is set to 30 seconds by default. It can be changed e.g. to 10 seconds by adding the argument `timeout=10`.
Expand Down

0 comments on commit ce7a6d1

Please sign in to comment.