Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion CaloCluster/fcl/prolog.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,29 @@ CaloCluster : {
strategy : 0
diagLevel : 0
}

CaloClusterFastMaker: {
module_type : "CaloClusterFast"
caloHitCollection : "CaloHitFastMaker:calo"
EminSeed : 10
EnoiseCut : 1
ExpandCut : 1
deltaTime : 10
diagLevel : 0
extendSearch: true
minSiPMPerHit: 2
timeOffset: -61
Comment thread
bechenard marked this conversation as resolved.
}
}

CaloCluster : { @table::CaloCluster
producers : {
CaloProtoClusterMaker : { @table::CaloCluster.CaloProtoClusterMaker }
CaloClusterMaker : { @table::CaloCluster.CaloClusterMaker }
CaloClusterFastMaker : { @table::CaloCluster.CaloClusterFastMaker }
}

Reco : [ CaloProtoClusterMaker, CaloClusterMaker ]
Reco : [ CaloProtoClusterMaker, CaloClusterMaker, CaloClusterFastMaker ]
}

END_PROLOG
1 change: 0 additions & 1 deletion CaloCluster/inc/ClusterUtils.hh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ namespace mu2e {
double e9 () const;
double e25 () const;


private:
const Calorimeter& cal_;
const CaloHitPtrVector hits_;
Expand Down
7 changes: 4 additions & 3 deletions CaloCluster/src/ClusterUtils.cc
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ namespace mu2e {
}




//-------------------------------------------------------------------------------------------------
CLHEP::Hep3Vector ClusterUtils::cog3Vector() const
{
double sx(0),sy(0),sz(0),sx2(0),sy2(0),sw(0);
Expand All @@ -55,13 +54,15 @@ namespace mu2e {
return cal_.geomUtil().mu2eToDiskFF(iSection,cogMu2eFrame);
}

//-------------------------------------------------------------------------------------------------
double ClusterUtils::secondMoment() const
{
double sx(0),sy(0),sz(0),sx2(0),sy2(0),sw(0);
fill(sx,sy,sz,sx2,sy2,sw);
return sx2-sx*sx/sw + sy2-sy*sy/sw;
return (sx2-sx*sx/sw + sy2-sy*sy/sw)/sw;
}

//-------------------------------------------------------------------------------------------------
void ClusterUtils::fill(double& sx, double& sy, double& sz, double& sx2, double& sy2, double& sw) const
{
int iSection = cal_.crystal(hits_[0]->crystalID()).diskID();
Expand Down
12 changes: 12 additions & 0 deletions CaloDiag/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,16 @@ cet_build_plugin(CaloNNDiag art::module
Offline::RecoDataProducts
)

cet_build_plugin(CaloNNTrain art::module
REG_SOURCE src/CaloNNTrain_module.cc
LIBRARIES REG
art_root_io::TFileService_service
Offline::CaloCluster
Offline::CalorimeterGeom
Offline::DataProducts
Offline::GeometryService
Offline::MCDataProducts
Offline::RecoDataProducts
)

install_source(SUBDIRS src)
34 changes: 34 additions & 0 deletions CaloDiag/fcl/prolog.fcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#include "Offline/Compression/fcl/prolog.fcl"
#include "Offline/CaloMC/fcl/prolog.fcl"
#include "Offline/CaloReco/fcl/prolog.fcl"
#include "Offline/CaloCluster/fcl/prolog.fcl"

BEGIN_PROLOG
CaloNNDiag : {
module_type : CaloNNDiag
vdCollection : "compressDigiMCs:virtualdetector"
caloHitCollection : CaloHitMaker
caloClusterCollection : CaloClusterMaker
caloHitTruth : CaloHitTruthMatch
caloClusterTruth : CaloClusterTruthMatch
minCluEnergy : 0
}

CaloNNTrain: {
module_type : CaloNNTrain
caloClusterCollection : CaloClusterMaker
caloClusterMCCollection : CaloClusterTruthMatch
minEtoTest : 40
MCEdepCut : 3
diagLevel : 0
}


CaloDiag : {
analyzers : {
CaloNNDiag : @local::CaloNNDiag
CaloNNTrain : @local::CaloNNTrain
}
}

END_PROLOG
Loading