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
24 changes: 18 additions & 6 deletions Analyses/src/CollectionSizeAnalyzer_module.cc
Original file line number Diff line number Diff line change
Expand Up @@ -62,17 +62,29 @@ namespace mu2e {
void doSimParticles(const art::Event& event);

public:
explicit CollectionSizeAnalyzer(const fhicl::ParameterSet& pset);

struct Config {
using Name=fhicl::Name;
using Comment=fhicl::Comment;
//using Atom=fhicl::Atom;
fhicl::Atom<bool> useModuleLabel{Name("useModuleLabel"), Comment("Include input module label into collection name in the plots") };
fhicl::Atom<bool> useInstanceName{Name("useInstanceName"), Comment("Include input instance name into collection name in the plots")};
fhicl::Atom<bool> useProcessName{Name("useProcessName"), Comment("Include input process name into collection name in the plots")};
};

using Parameters = art::EDAnalyzer::Table<Config>;
explicit CollectionSizeAnalyzer(const Parameters& conf);

virtual void analyze(const art::Event& event);
};

//================================================================
CollectionSizeAnalyzer::CollectionSizeAnalyzer(const fhicl::ParameterSet& pset)
: art::EDAnalyzer(pset)
CollectionSizeAnalyzer::CollectionSizeAnalyzer(const Parameters& conf)
: art::EDAnalyzer(conf)
, hStepPointSize_(0)
, useModuleLabel_(pset.get<bool>("useModuleLabel"))
, useInstanceName_(pset.get<bool>("useInstanceName"))
, useProcessName_(pset.get<bool>("useProcessName"))
, useModuleLabel_(conf().useModuleLabel())
, useInstanceName_(conf().useInstanceName())
, useProcessName_(conf().useProcessName())
{
art::ServiceHandle<art::TFileService> tfs;
hStepPointSize_ = tfs->make<TProfile>("avgStepPointsSize", "Average step point collection size", 1, 0., 0.);
Expand Down
1 change: 0 additions & 1 deletion JobConfig/beam/PS.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ physics : {
collectionSizes: {
module_type: CollectionSizeAnalyzer
useModuleLabel: true useInstanceName: true useProcessName: false
maxStepPointMultiplicity: 500
}
}

Expand Down
1 change: 0 additions & 1 deletion JobConfig/beam/beam_defs_g4s1.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ physics : {
collectionSizes: {
module_type: CollectionSizeAnalyzer
useModuleLabel: true useInstanceName: true useProcessName: false
maxStepPointMultiplicity: 500
}
}

Expand Down
1 change: 0 additions & 1 deletion JobConfig/beam/beam_g4s1MT.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ physics : {
collectionSizes: {
module_type: CollectionSizeAnalyzer
useModuleLabel: true useInstanceName: true useProcessName: false
maxStepPointMultiplicity: 500
}
}

Expand Down
1 change: 0 additions & 1 deletion JobConfig/pions/pions_g4s1.fcl
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ physics : {
userModuleLabel : true
useInstanceName : true
useProcessName : false
maxStepPointMultiplicity : 500
}
} // analyzers

Expand Down