diff --git a/benchmarks/clustering/full_cal_clusters.sh b/benchmarks/clustering/full_cal_clusters.sh index d30f08fb0bfa9043e1948fccd307b6a425929afb..ee6d64c6e65404cf16c2388ba525206b2e3c72cd 100644 --- a/benchmarks/clustering/full_cal_clusters.sh +++ b/benchmarks/clustering/full_cal_clusters.sh @@ -130,7 +130,7 @@ fi # Run analysis scripts FULL_CAL_SCRIPT_DIR=benchmarks/clustering/scripts python ${FULL_CAL_SCRIPT_DIR}/cluster_plots.py ${JUGGLER_SIM_FILE} ${JUGGLER_REC_FILE} -o results \ - --collections "EcalEndcapNClusters, EcalEndcapPClusters, EcalBarrelClusters, + --collections "EcalEndcapNClusters, EcalEndcapPClusters, EcalBarrelImagingClusters, HcalEndcapNClusters, HcalEndcapPClusters, HcalBarrelClusters" root_filesize=$(stat --format=%s "${JUGGLER_REC_FILE}") diff --git a/benchmarks/clustering/options/full_cal_reco.py b/benchmarks/clustering/options/full_cal_reco.py index 5e66e82b2b8860fb9f4b5d47096199aa1b7db363..4cc4b8415358fda9aea243b721b84daa08613ea2 100644 --- a/benchmarks/clustering/options/full_cal_reco.py +++ b/benchmarks/clustering/options/full_cal_reco.py @@ -162,22 +162,22 @@ cb_ecal_daq = dict( cb_ecal_digi = CalHitDigi("cb_ecal_digi", inputHitCollection="EcalBarrelHits", - outputHitCollection="EcalBarrelHitsDigi", + outputHitCollection="EcalBarrelImagingHitsDigi", energyResolutions=[0., 0.02, 0.], # 2% flat resolution **cb_ecal_daq) cb_ecal_reco = ImCalPixelReco("cb_ecal_reco", inputHitCollection=cb_ecal_digi.outputHitCollection, - outputHitCollection="EcalBarrelHitsReco", + outputHitCollection="EcalBarrelImagingHitsReco", thresholdFactor=3, # about 20 keV - readoutClass="EcalBarrelHits", # readout class + readoutClass="EcalBarrelImagingHits", # readout class layerField="layer", # field to get layer id sectorField="module", # field to get sector id **cb_ecal_daq) cb_ecal_cl = ImagingCluster("cb_ecal_cl", inputHitCollection=cb_ecal_reco.outputHitCollection, - outputProtoClusterCollection="EcalBarrelProtoClusters", + outputProtoClusterCollection="EcalBarrelImagingProtoClusters", localDistXY=[2.*mm, 2*mm], # same layer layerDistEtaPhi=[10*mrad, 10*mrad], # adjacent layer neighbourLayersRange=2, # id diff for adjacent layer @@ -187,9 +187,9 @@ cb_ecal_clreco = ImagingClusterReco("cb_ecal_clreco", samplingFraction=cb_ecal_sf, inputHitCollection=cb_ecal_cl.inputHitCollection, inputProtoClusterCollection=cb_ecal_cl.outputProtoClusterCollection, - outputClusterCollection="EcalBarrelClusters", - outputInfoCollection="EcalBarrelClustersInfo", - outputLayerCollection="EcalBarrelLayers") + outputClusterCollection="EcalBarrelImagingClusters", + outputInfoCollection="EcalBarrelImagingClustersInfo", + outputLayerCollection="EcalBarrelImagingLayers") #Central ECAL SciFi # use the same daq_setting for digi/reco pair diff --git a/benchmarks/ecal/options/barrel.py b/benchmarks/ecal/options/barrel.py index a7d22cda4cf6469bf795d611b444135d7ef8e20a..96fcf9d78e78344ddf8870efc08219c8f1db725d 100644 --- a/benchmarks/ecal/options/barrel.py +++ b/benchmarks/ecal/options/barrel.py @@ -59,22 +59,22 @@ cb_ecal_daq = dict( cb_ecal_digi = CalHitDigi("cb_ecal_digi", inputHitCollection="EcalBarrelHits", - outputHitCollection="EcalBarrelHitsDigi", + outputHitCollection="EcalBarrelImagingHitsDigi", energyResolutions=[0., 0.02, 0.], # 2% flat resolution **cb_ecal_daq) cb_ecal_reco = ImCalPixelReco("cb_ecal_reco", inputHitCollection=cb_ecal_digi.outputHitCollection, - outputHitCollection="EcalBarrelHitsReco", + outputHitCollection="EcalBarrelImagingHitsReco", thresholdFactor=3, # about 20 keV - readoutClass="EcalBarrelHits", # readout class + readoutClass="EcalBarrelImagingHits", # readout class layerField="layer", # field to get layer id sectorField="module", # field to get sector id **cb_ecal_daq) cb_ecal_cl = ImagingCluster("cb_ecal_cl", inputHitCollection=cb_ecal_reco.outputHitCollection, - outputProtoClusterCollection="EcalBarrelProtoClusters", + outputProtoClusterCollection="EcalBarrelImagingProtoClusters", localDistXY=[2.*mm, 2*mm], # same layer layerDistEtaPhi=[10*mrad, 10*mrad], # adjacent layer neighbourLayersRange=2, # id diff for adjacent layer @@ -84,9 +84,9 @@ cb_ecal_clreco = ImagingClusterReco("cb_ecal_clreco", samplingFraction=cb_ecal_sf, inputHitCollection=cb_ecal_cl.inputHitCollection, inputProtoClusterCollection=cb_ecal_cl.outputProtoClusterCollection, - outputClusterCollection="EcalBarrelClusters", - outputLayerCollection="EcalBarrelLayers", - outputInfoCollection="EcalBarrelClustersInfo") + outputClusterCollection="EcalBarrelImagingClusters", + outputLayerCollection="EcalBarrelImagingLayers", + outputInfoCollection="EcalBarrelImagingClustersInfo") podout.outputCommands = ['drop *', 'keep mcparticles2', diff --git a/benchmarks/ecal/run_emcal_benchmarks.py b/benchmarks/ecal/run_emcal_benchmarks.py index 2380e4045d515d14a72091c3b245d25a70976abd..c70ca0bec892b5aeb5322ebc3df72d8843f7ae3c 100755 --- a/benchmarks/ecal/run_emcal_benchmarks.py +++ b/benchmarks/ecal/run_emcal_benchmarks.py @@ -24,11 +24,11 @@ default_type = { 'barrel': [ ['barrel.py'], ['draw_clusters.py'], - ['EcalBarrelClusters']], + ['EcalBarrelImagingClusters']], # 'all': [ # ['all_ecal.py'], # ['draw_clusters.py'], -# ['EcalEndcapNClusters', 'EcalEndcapPClusters', 'EcalBarrelClusters']], +# ['EcalEndcapNClusters', 'EcalEndcapPClusters', 'EcalBarrelImagingClusters']], } default_compact = os.path.join(os.environ.get('DETECTOR_PATH', os.environ.get('DETECTOR_PATH', '')), diff --git a/benchmarks/full/options/full_reconstruction.py b/benchmarks/full/options/full_reconstruction.py index a479127245e67fbc53a4b5c936f4f65858bcfa98..2099bcc2fda732a85adf99feec1f02bbb1f88cce 100644 --- a/benchmarks/full/options/full_reconstruction.py +++ b/benchmarks/full/options/full_reconstruction.py @@ -32,7 +32,7 @@ with open('config/emcal_barrel_calibration.json') as f: print(calib_data) -cb_ecal_sf = float(calib_data['sampling_fraction_img']) +img_barrel_sf = float(calib_data['sampling_fraction_img']) scifi_barrel_sf = float(calib_data['sampling_fraction_scfi']) # input and output @@ -222,42 +222,42 @@ ci_ecal_clreco = RecoCoG("ci_ecal_clreco", samplingFraction=ci_ecal_sf) # Central Barrel Ecal (Imaging Cal.) -cb_ecal_daq = dict( +img_barrel_daq = dict( dynamicRangeADC=3*units.MeV, capacityADC=8192, pedestalMean=400, pedestalSigma=20) # about 6 keV -cb_ecal_digi = CalHitDigi("cb_ecal_digi", +img_barrel_digi = CalHitDigi("img_barrel_digi", inputHitCollection="EcalBarrelHits", - outputHitCollection="EcalBarrelHitsDigi", + outputHitCollection="EcalBarrelImagingHitsDigi", energyResolutions=[0., 0.02, 0.], # 2% flat resolution - **cb_ecal_daq) + **img_barrel_daq) -cb_ecal_reco = ImCalPixelReco("cb_ecal_reco", - inputHitCollection=cb_ecal_digi.outputHitCollection, - outputHitCollection="EcalBarrelHitsReco", +img_barrel_reco = ImCalPixelReco("img_barrel_reco", + inputHitCollection=img_barrel_digi.outputHitCollection, + outputHitCollection="EcalBarrelImagingHitsReco", thresholdFactor=3, # about 20 keV - readoutClass="EcalBarrelHits", # readout class + readoutClass="EcalBarrelImagingHits", # readout class layerField="layer", # field to get layer id sectorField="module", # field to get sector id - **cb_ecal_daq) + **img_barrel_daq) -cb_ecal_cl = ImagingCluster("cb_ecal_cl", - inputHitCollection=cb_ecal_reco.outputHitCollection, - outputProtoClusterCollection="EcalBarrelProtoClusters", +img_barrel_cl = ImagingCluster("img_barrel_cl", + inputHitCollection=img_barrel_reco.outputHitCollection, + outputProtoClusterCollection="EcalBarrelImagingProtoClusters", localDistXY=[2.*units.mm, 2*units.mm], # same layer layerDistEtaPhi=[10*units.mrad, 10*units.mrad], # adjacent layer neighbourLayersRange=2, # id diff for adjacent layer sectorDist=3.*units.cm) # different sector -cb_ecal_clreco = ImagingClusterReco("cb_ecal_clreco", - samplingFraction=cb_ecal_sf, - inputHitCollection=cb_ecal_cl.inputHitCollection, - inputProtoClusterCollection=cb_ecal_cl.outputProtoClusterCollection, - outputClusterCollection="EcalBarrelClusters", - outputInfoCollection="EcalBarrelClustersInfo", - outputLayerCollection="EcalBarrelLayers") +img_barrel_clreco = ImagingClusterReco("img_barrel_clreco", + samplingFraction=img_barrel_sf, + inputHitCollection=img_barrel_cl.inputHitCollection, + inputProtoClusterCollection=img_barrel_cl.outputProtoClusterCollection, + outputClusterCollection="EcalBarrelImagingClusters", + outputInfoCollection="EcalBarrelImagingClustersInfo", + outputLayerCollection="EcalBarrelImagingLayers") # Central ECAL SciFi scfi_barrel_daq = dict( @@ -568,7 +568,7 @@ ApplicationMgr( ecal_digi, ecal_reco, #simple_cluster, ce_ecal_digi, ce_ecal_reco, ce_ecal_cl, ce_ecal_clreco, ci_ecal_digi, ci_ecal_reco, ci_ecal_merger, ci_ecal_cl, ci_ecal_clreco, - cb_ecal_digi, cb_ecal_reco, cb_ecal_cl, cb_ecal_clreco, + img_barrel_digi, img_barrel_reco, img_barrel_cl, img_barrel_clreco, scfi_barrel_digi, scfi_barrel_reco, scfi_barrel_merger, scfi_barrel_cl, scfi_barrel_clreco, cb_hcal_digi, cb_hcal_reco, cb_hcal_merger, cb_hcal_cl, cb_hcal_clreco, ce_hcal_digi, ce_hcal_reco, ce_hcal_merger, ce_hcal_cl, ce_hcal_clreco, diff --git a/benchmarks/imaging_ecal/options/hybrid_cluster.py b/benchmarks/imaging_ecal/options/hybrid_cluster.py index 4f91158dbe94710e81e421df3016bd6239bbf18d..fb312a15d8fa8c4c64a433a6c8659f91598fd259 100644 --- a/benchmarks/imaging_ecal/options/hybrid_cluster.py +++ b/benchmarks/imaging_ecal/options/hybrid_cluster.py @@ -65,14 +65,14 @@ imcaldaq = dict( imcaldigi = CalHitDigi('imcal_digi', # OutputLevel=DEBUG, inputHitCollection='EcalBarrelHits', - outputHitCollection='DigiEcalBarrelHits', + outputHitCollection='DigiEcalBarrelImagingHits', energyResolutions=[0., 0.02, 0.], **imcaldaq) imcalreco = ImagingPixelReco('imcal_reco', # OutputLevel=DEBUG, inputHitCollection=imcaldigi.outputHitCollection, - outputHitCollection='RecoEcalBarrelHits', - readoutClass='EcalBarrelHits', + outputHitCollection='RecoEcalBarrelImagingHits', + readoutClass='EcalBarrelImagingHits', layerField='layer', sectorField='module', **imcaldaq) @@ -80,7 +80,7 @@ imcalreco = ImagingPixelReco('imcal_reco', imcalcluster = ImagingTopoCluster('imcal_cluster', # OutputLevel=DEBUG, inputHitCollection=imcalreco.outputHitCollection, - outputProtoClusterCollection='EcalBarrelProtoClusters', + outputProtoClusterCollection='EcalBarrelImagingProtoClusters', localDistXY=[2.*mm, 2*mm], layerDistEtaPhi=[10*mrad, 10*mrad], neighbourLayersRange=2, @@ -89,9 +89,9 @@ clusterreco = ImagingClusterReco('imcal_clreco', # OutputLevel=DEBUG, inputHitCollection=imcalcluster.inputHitCollection, inputProtoClusterCollection=imcalcluster.outputProtoClusterCollection, - outputLayerCollection='EcalBarrelClustersLayers', - outputClusterCollection='EcalBarrelClusters', - outputInfoCollection='EcalBarrelClustersInfo', + outputLayerCollection='EcalBarrelImagingClustersLayers', + outputClusterCollection='EcalBarrelImagingClusters', + outputInfoCollection='EcalBarrelImagingClustersInfo', samplingFraction=kwargs['img_sf']) # scfi layers diff --git a/benchmarks/imaging_ecal/options/imaging_2dcluster.py b/benchmarks/imaging_ecal/options/imaging_2dcluster.py index d2a038ca3b92b2a3c2ea2afb23228ed78c029ef8..7bb5fe80430481e8b781f04d2e1c37ea4688ad0d 100644 --- a/benchmarks/imaging_ecal/options/imaging_2dcluster.py +++ b/benchmarks/imaging_ecal/options/imaging_2dcluster.py @@ -53,14 +53,14 @@ imcal_barrel_daq = dict( imcal_barrel_digi = CalHitDigi('imcal_barrel_digi', inputHitCollection='EcalBarrelHits', - outputHitCollection='EcalBarrelHitsDigi', + outputHitCollection='EcalBarrelImagingHitsDigi', **imcal_barrel_daq) imcal_barrel_reco = CalHitReco('imcal_barrel_reco', inputHitCollection=imcal_barrel_digi.outputHitCollection, - outputHitCollection='EcalBarrelHitsReco', + outputHitCollection='EcalBarrelImagingHitsReco', thresholdFactor=5.0, - readoutClass='EcalBarrelHits', + readoutClass='EcalBarrelImagingHits', localDetFields=['system', 'module'], # use local coordinates in each module (stave) **imcal_barrel_daq) @@ -68,13 +68,13 @@ imcal_barrel_reco = CalHitReco('imcal_barrel_reco', imcal_barrel_merger = CalHitsProj('imcal_barrel_merger', # OutputLevel=DEBUG, inputHitCollection=imcal_barrel_reco.outputHitCollection, - outputHitCollection='EcalBarrelHitsMerge', + outputHitCollection='EcalBarrelImagingHitsMerge', gridSizes=[0.004, 0.004*rad]) imcal_barrel_cl = IslandCluster('imcal_barrel_cl', # OutputLevel=DEBUG, inputHitCollection=imcal_barrel_merger.outputHitCollection, - outputProtoClusterCollection='EcalBarrelProtoClusters', + outputProtoClusterCollection='EcalBarrelImagingProtoClusters', minClusterCenterEdep=1.*MeV, minClusterHitEdep=0.1*MeV, splitCluster=True, @@ -84,8 +84,8 @@ imcal_barrel_clreco = RecoCoG('imcal_barrel_clreco', # OutputLevel=DEBUG, inputHitCollection=imcal_barrel_cl.inputHitCollection, inputProtoClusterCollection = imcal_barrel_cl.outputProtoClusterCollection, - outputClusterCollection='EcalBarrelClusters', - outputInfoCollection='EcalBarrelClustersInfo', + outputClusterCollection='EcalBarrelImagingClusters', + outputInfoCollection='EcalBarrelImagingClustersInfo', logWeightBase=6.2, samplingFraction=kwargs['img_sf']) diff --git a/benchmarks/imaging_ecal/options/imaging_topocluster.py b/benchmarks/imaging_ecal/options/imaging_topocluster.py index 94901baa93f49326f8f9ccd3028955f5b408b784..cd7b5d6709a3a1d1017b9dcab61287c7b64da0e0 100644 --- a/benchmarks/imaging_ecal/options/imaging_topocluster.py +++ b/benchmarks/imaging_ecal/options/imaging_topocluster.py @@ -58,14 +58,14 @@ daq_setting = dict( imcaldigi = CalorimeterHitDigi("imcal_digi", # OutputLevel=DEBUG, inputHitCollection="EcalBarrelHits", - outputHitCollection="DigiEcalBarrelHits", + outputHitCollection="DigiEcalBarrelImagingHits", energyResolutions=[0., 0.02, 0.], **daq_setting) imcalreco = ImagingPixelReco("imcal_reco", # OutputLevel=DEBUG, inputHitCollection=imcaldigi.outputHitCollection, - outputHitCollection="RecoEcalBarrelHits", - readoutClass="EcalBarrelHits", + outputHitCollection="RecoEcalBarrelImagingHits", + readoutClass="EcalBarrelImagingHits", layerField="layer", sectorField="module", **daq_setting) @@ -73,7 +73,7 @@ imcalreco = ImagingPixelReco("imcal_reco", imcalcluster = ImagingTopoCluster("imcal_cluster", # OutputLevel=DEBUG, inputHitCollection=imcalreco.outputHitCollection, - outputProtoClusterCollection="EcalBarrelProtoClusters", + outputProtoClusterCollection="EcalBarrelImagingProtoClusters", localDistXY=[2.*units.mm, 2*units.mm], layerDistEtaPhi=[10*units.mrad, 10*units.mrad], neighbourLayersRange=2, @@ -83,9 +83,9 @@ clusterreco = ImagingClusterReco("imcal_clreco", # OutputLevel=DEBUG, inputHitCollection=imcalcluster.inputHitCollection, inputProtoClusterCollection=imcalcluster.outputProtoClusterCollection, - outputLayerCollection="EcalBarrelClustersLayers", - outputClusterCollection="EcalBarrelClusters", - outputInfoCollection="EcalBarrelClustersInfo", + outputLayerCollection="EcalBarrelImagingClustersLayers", + outputClusterCollection="EcalBarrelImagingClusters", + outputInfoCollection="EcalBarrelImagingClustersInfo", samplingFraction=sf) out.outputCommands = ["keep *"] diff --git a/benchmarks/imaging_ecal/run_emcal_barrel.sh b/benchmarks/imaging_ecal/run_emcal_barrel.sh index 0dca31e54a940b5ce3ac2d4e186e02dc7cce9b8e..843e0febdefdd36865aeb1d3951bc36844317ba8 100644 --- a/benchmarks/imaging_ecal/run_emcal_barrel.sh +++ b/benchmarks/imaging_ecal/run_emcal_barrel.sh @@ -116,7 +116,7 @@ fi # Plot clusters first FULL_CAL_SCRIPT_DIR=benchmarks/clustering/scripts python ${FULL_CAL_SCRIPT_DIR}/cluster_plots.py ${CB_EMCAL_SIM_FILE} ${CB_EMCAL_REC_FILE} -o results \ - --collections "EcalBarrelClusters, EcalBarrelScFiClusters" + --collections "EcalBarrelImagingClusters, EcalBarrelScFiClusters" # check required python modules python -m pip install -r benchmarks/imaging_ecal/requirements.txt diff --git a/benchmarks/imaging_ecal/run_imcal_pion0.sh b/benchmarks/imaging_ecal/run_imcal_pion0.sh index 9506c117087195eedccf108621dce3918eb237fe..cac64c8cf232d5663691ab157c3ac357c7a7b5a5 100644 --- a/benchmarks/imaging_ecal/run_imcal_pion0.sh +++ b/benchmarks/imaging_ecal/run_imcal_pion0.sh @@ -111,7 +111,7 @@ fi # Plot clusters first FULL_CAL_SCRIPT_DIR=benchmarks/clustering/scripts python ${FULL_CAL_SCRIPT_DIR}/cluster_plots.py ${CB_EMCAL_SIM_FILE} ${CB_EMCAL_REC_FILE} -o results \ - --collections "EcalBarrelClusters" + --collections "EcalBarrelImagingClusters" root_filesize=$(stat --format=%s "${CB_EMCAL_REC_FILE}") if [[ "${CB_EMCAL_NUMEV}" -lt "500" ]] ; then