Generating and Viewing Events - Thomas-Ham/larreco GitHub Wiki
Generate some events
The fcl file specifies the type of events we generate
lar -c prodsingle_sbnd.fcl -o outputfile.root -n 10 # the -n 10 means we will generate 10 events
Run GEANT4 on the generated events
lar -c standard_g4_sbnd.fcl outputfile.root -o outputfile_g4.root
Run detector simulation on the events
lar -c standard_detsim_sbnd.fcl outputfile_g4.root -o outputfile_g4_detsim.root
Run detector reconstruction on the events
lar -c standard_reco_sbnd_basic.fcl outputfile_g4_detsim.root -o outputfile_g4_detsim_reco.root
if reco gives error e.g.
%MSG-s ArtException: ClusterCrawler:cccluster@Construction 17-Apr-2019
18:47:13 CDT ModuleConstruction
cet::exception caught in art
---- Can't find key BEGIN
CalDataModuleLabel
---- Can't find key END
%MSG
might need to add --prune-config
- see https://cdcvs.fnal.gov/redmine/projects/larsoft/wiki/Update_to_art_v3_02
Viewing Events
Open event display
lar -c evd_sbnd.fcl outputfile_g4_detsim_reco.root
Event dump - list all object in event
lar -c eventdump.fcl outputfile_g4_detsim_reco.root -n 1
Accessing premade samples
https://cdcvs.fnal.gov/redmine/projects/sbn-analysis-group/wiki/How_to_access_the_SBND_samples
https://cdcvs.fnal.gov/redmine/projects/sbn-analysis-group/wiki/How_to_access_SBND_sample
SAM Files - List Samples
samweb list-definitions
List Files in Sample
samweb list-definition-files workshop_SBNWorkshop0319_prodcorsika_cosmics_cmc_reco
Get Info on File
samweb get-metadata reco-62d37c8a-f09e-40e2-a002-9d9ff0247cbd.root
Get Location of File
samweb locate-file reco-62d37c8a-f09e-40e2-a002-9d9ff0247cbd.root
Actually Get File (should (probably) do it on /pnfs and might take a while)
setup sbnd
setup fife_utils
ifdh_fetch reco-62d37c8a-f09e-40e2-a002-9d9ff0247cbd.root