Kalanand's September 2010 Log
September 9th
New PickEvents Tool
Charles advertised a new pick events tool today:
https://twiki.cern.ch/twiki/bin/view/CMSPublic/WorkBookPickEvents
This tool will work both picking a small number of events out of
locally available files as well as selecting a large number of events
_not available locally._
Update: Please use the following new tag:
V08-01-02 PhysicsTools/Utilities
The previous tag had a subtle bug. The tool
picked events in a different order
from the one in the input text file but in a reproducible way, i.e.,
always in the same different order.
The new tag has got this fixed.
September 21st
Using PickEvents tool
To run the script interactively do the following, for example
edmPickEvents.py "/EG/Run2010A-PromptReco-v4/RECO" 140160:98:82878561 140160,101,85437704
where
* /EG/Run2010A-PromptReco-v4/RECO is the dataset you want to pick events from
* 140160:98:82878561 and 140160:101:85437704 are the two events you want to pick. The syntax is Run:Lumi:Event
or
edmPickEvents.py "/EG/Run2010A-PromptReco-v4/RECO" events.txt
If you are running over large number of events (or if the sample is not available locally
at FNAL) the script will automatically create crab config to submit.
**** Make sure to set the crab server option to 0 and change lumi section per job to some
sensible number (say, 200) in "pickevents_crab.config" before creating crab jobs.
More details here: https://twiki.cern.ch/twiki/bin/view/CMSPublic/WorkBookPickEvents
September 30th
Providing PoolSource input list as a text file
Take a look at VarParsing:
https://twiki.cern.ch/twiki/bin/view/CMSPublic/SWGuideAboutPythonConfigFile#VarParsing_Example
It allows for loading files from a text file and even allows you to
specify which files (and other options) from the command line.
Bugifx
process.source = cms.Source("PoolSource",
fileNames = cms.untracked.vstring( [line.strip() for line in
file('input.txt').readlines()] )
)
Apparently the vstring() constructor does not accept a generator,
unlike lists and tuples.
Update:
See also:
https://twiki.cern.ch/twiki/bin/view/CMSPublic/SWGuidePythonTips#Running_on_more_than_255_files
Go to August's log
Last modified: Thu Sept 30 19:03:21 CST 2010