#include <MdLDFFinder.h>
Public Types | |
enum | LDFType { eKascadeGrande, eUndef_I, eUndef_II } |
Kind of possible ldf functions to be used. More... | |
enum | MinMethodType { eLikelihood, eLikelihood2, eLikelihood3 } |
Kind of possible minimization criteria to be used. More... | |
enum | ResultFlag { eSuccess, eFailure, eBreakLoop, eContinueLoop } |
Flag returned by module methods to the RunController. More... | |
enum | VersionInfoType { eFilename = 1, eRevisionNumber = 2, eDate = 3, eTime = 4, eLastEditor = 5 } |
Different types of version info that can be retrieved from GetVersionInfo. More... | |
Public Member Functions | |
VModule::ResultFlag | Finish () |
Finish: invoked at end of the run (NOT end of the event) More... | |
utl::Stopwatch & | GetStopwatch () |
const utl::Stopwatch & | GetStopwatch () const |
std::string | GetVersionInfo (const VersionInfoType v) const |
Retrieve different sorts of module version info. More... | |
VModule::ResultFlag | Init () |
Initialize: invoked at beginning of run (NOT beginning of event) More... | |
void | InitTiming () |
MdLDFFinder () | |
VModule::ResultFlag | Run (evt::Event &e) |
Run: invoked once per event. More... | |
ResultFlag | RunWithTiming (evt::Event &event) |
~MdLDFFinder () | |
Static Public Member Functions | |
static std::string | GetResultFlagByName (const ResultFlag flag) |
Static Public Attributes | |
static const char *const | kLDFTags [] = { "KascadeGrande", "ToBeDef_I", "ToBeDef_II" } |
Tags for the types of LDF. More... | |
static const char *const | kMinMethodTags [] = { "Likelihood", "Likelihood2", "Likelihood3" } |
Tags for the types of MinMethod. More... | |
Protected Types | |
enum | InfoLevel { eInfoNone = 0, eInfoFinal = 1, eInfoIntermediate = 2, eInfoDebug = 3 } |
Protected Attributes | |
int | fInfoLevel = 0 |
Private Member Functions | |
double | CalculateBeta (const double theta) const |
double | CalculateChi2 (const CounterList counters, const std::vector< double > parameters, const utl::Point rCore, const utl::Vector rAxis) const |
size_t | CalculateDegreesOfFreedom (const CounterList, const std::vector< bool >) const |
double | CalculateRho0Seed (const CounterList counters, const utl::Point rCore, const utl::Vector rAxis) const |
Estimate inital parameters. More... | |
void | FillModulesShowerPlaneDistances (const evt::ShowerSRecData &, const mdet::MDetector &, mevt::MEvent &) |
void | FillReconstructedParameters (evt::ShowerMRecData &, const ROOT::Minuit2::MnUserParameterState &, double) |
void | FillTabulatedFunction (evt::ShowerMRecData &, const std::vector< double > &fPars, const std::vector< double > &fErrPars) |
bool | FixBetaFlag (const CounterList, const utl::Point &, const utl::Vector &) const |
unsigned int | GetFreeParIndex (const std::vector< ROOT::Minuit2::MinuitParameter >, unsigned int) const |
REGISTER_MODULE ("MdLDFFinderAG", MdLDFFinder) | |
CounterList | SelectCandidateCounters (mevt::MEvent &) |
Fill the minimizer with the candidate modules from the event No efforr is made hare that the statuses of counters and modules are correct. This has to be checked in the event selector. More... | |
CounterList | SelectSilentCounters (mevt::MEvent &) |
void | SetLdfResiduals (CounterList counters, const std::vector< double > parameters, const utl::Point rCore, const utl::Vector rAxis) const |
Private Attributes | |
double | fA0 |
For beta parameterization: beta(theta) = a0 + a1 * sec(theta) + a2 * sec^2(theta) More... | |
double | fA1 |
double | fA2 |
double | fCounterSpacings1 |
double | fCounterSpacings2 |
double | fCounterSpacings3 |
unsigned int | fCountersToFixBeta |
bool | fFixBeta |
bool | fFixCoreFromSd |
std::unique_ptr< VLDFFunctor > | fLDF |
Object performing the LDF and MinMethod evaluation. More... | |
LDFType | fLDFType |
LDF and Minimization Method Types. More... | |
double | fLowLimToRelaxBeta |
std::unique_ptr < VMinMethodFunctor > | fMinimizer |
MinMethodType | fMinMethodType |
double | fReferenceDistance |
size_t | fSaturationLimit |
size_t | fSilentLimit |
double | fUppLimToRelaxBeta |
bool | fUseSaturated |
bool | fUseSilent |
const mdet::MDetector * | mDetector |
utl::CoordinateSystemPtr | siteCS |
Make detector data and coordinate system available to all methods. More... | |
Definition at line 33 of file MdLDFFinder.h.
|
protectedinherited |
Kind of possible ldf functions to be used.
Enumerator | |
---|---|
eKascadeGrande |
Kascade-Grande LDF, see... |
eUndef_I |
Undefined I |
eUndef_II |
Undefined II |
Definition at line 37 of file MdLDFFinder.h.
Kind of possible minimization criteria to be used.
Enumerator | |
---|---|
eLikelihood |
Original likelihood (Poisson) |
eLikelihood2 |
Profile likelihood (Binomial with time windows) |
eLikelihood3 |
Likelihood (Binomial infinite window and corner-clipping correction) |
Definition at line 46 of file MdLDFFinder.h.
|
inherited |
Flag returned by module methods to the RunController.
Enumerator | |
---|---|
eSuccess |
Report success to RunController. |
eFailure |
Report failure to RunController, causing RunController to terminate execution. |
eBreakLoop |
Break current loop. It works for nested loops too! |
eContinueLoop |
Skip remaining modules in the current loop and continue with next iteration of the loop. |
|
inherited |
MdLDFFinderAG::MdLDFFinder::MdLDFFinder | ( | ) |
Definition at line 58 of file MdLDFFinder.cc.
MdLDFFinderAG::MdLDFFinder::~MdLDFFinder | ( | ) |
Definition at line 62 of file MdLDFFinder.cc.
|
private |
Definition at line 504 of file MdLDFFinder.cc.
References std::pow().
|
private |
Definition at line 643 of file MdLDFFinder.cc.
References fwk::LocalCoordinateSystemConstructor< Policy >::Create(), utl::cross(), utl::BasicVector< HepVector >::GetCosTheta(), mevt::Counter::GetId(), det::DetectorComponent< C, ManagerProvider >::GetId(), utl::AxialVector::GetMag(), mdet::Counter::GetModule(), det::MPositionable< Config >::GetPosition(), mevt::Counter::ModulesBegin(), and mevt::Counter::ModulesEnd().
|
private |
Definition at line 696 of file MdLDFFinder.cc.
References mevt::Counter::ModulesBegin(), and mevt::Counter::ModulesEnd().
|
private |
Estimate inital parameters.
Definition at line 512 of file MdLDFFinder.cc.
References utl::cross(), mevt::Counter::GetId(), utl::AxialVector::GetMag(), mevt::Counter::GetMuonDensity(), and max.
|
private |
Definition at line 722 of file MdLDFFinder.cc.
References mevt::MEvent::CountersBegin(), mevt::MEvent::CountersEnd(), mdet::MDetector::GetCounter(), det::DetectorComponent< C, ManagerProvider >::GetId(), mdet::Counter::GetModule(), det::MPositionable< Config >::GetPosition(), utl::BasicVector< HepVector >::GetRho(), evt::ShowerSRecData::GetShowerCoordinateSystem(), and mevt::ModuleRecData::SetSPDistance().
|
private |
Definition at line 412 of file MdLDFFinder.cc.
References SdMonteCarloPropagatorKVI::eBeta, SdHorizontalReconstructionNS::eCoreX, SdHorizontalReconstructionNS::eCoreY, SdMonteCarloPropagatorKVI::eShowerSize, evt::ShowerMRecData::IsGeometryReconstructed(), evt::ShowerMRecData::SetBeta(), evt::ShowerMRecData::SetBetaFixed(), evt::ShowerMRecData::SetCoreError(), evt::ShowerMRecData::SetCoreFixedLdf(), evt::ShowerMRecData::SetCorePosition(), evt::ShowerMRecData::SetCorrelationXY(), evt::ShowerMRecData::SetNMuRef(), and sqrt().
|
private |
Definition at line 380 of file MdLDFFinder.cc.
References utl::TabulatedFunctionErrors::Clear(), evt::ShowerMRecData::GetMLDF(), utl::m, utl::TabulatedFunctionErrors::PushBack(), and sqrt().
|
virtual |
Finish: invoked at end of the run (NOT end of the event)
This method is for things that should be done at the end of the run (for example, closing files or writing out histograms) {You must override this method in your concrete module}
Implements fwk::VModule.
Definition at line 298 of file MdLDFFinder.cc.
References io::eSuccess.
|
private |
Definition at line 307 of file MdLDFFinder.cc.
References utl::abs(), utl::Cross(), DEBUGLOG, utl::AxialVector::GetMag(), utl::BasicVector< HepVector >::GetX(), utl::BasicVector< HepVector >::GetY(), utl::BasicVector< HepVector >::GetZ(), INFO, and utl::m.
|
private |
Definition at line 483 of file MdLDFFinder.cc.
|
staticinherited |
Definition at line 8 of file VModule.cc.
References fwk::VModule::eBreakLoop, fwk::VModule::eContinueLoop, fwk::VModule::eFailure, and fwk::VModule::eSuccess.
Referenced by fwk::RunController::DoNextInSequence(), fwk::RunController::FinishBranch(), and fwk::RunController::InitBranch().
|
inlineinherited |
Definition at line 106 of file VModule.h.
References fwk::VModule::fStopwatch.
|
inlineinherited |
Definition at line 107 of file VModule.h.
References fwk::VModule::fStopwatch.
|
inherited |
Retrieve different sorts of module version info.
Definition at line 26 of file VModule.cc.
Referenced by fwk::CentralConfig::GetConfig(), ThresholdCalculatorKG::ThresholdCalculator::Init(), fdDoubleBumpFinder::FdDoubleBumpFinder::Init(), LaserGeneratorNA::LaserGenerator::Init(), LaserLightSimulatorNA::LaserLightSimulator::Init(), FdElectronicsSimulatorOG::FdElectronicsSimulator::Init(), TelescopeSimulatorKG::TelescopeSimulator::Init(), TelescopeSimulatorKG2::TelescopeSimulator::Init(), SdSimpleSimKG::SdSimpleSim::Init(), ShowerPhotonGeneratorOG::ShowerPhotonGenerator::Init(), and testRunController::testModuleVersionInfo().
|
virtual |
Initialize: invoked at beginning of run (NOT beginning of event)
This method is for things that should be done once at the beginning of a run (for example, booking histograms, performing calculations that need to be done only once, initializing parameters) {You must override this method in your concrete module}
Implements fwk::VModule.
Definition at line 67 of file MdLDFFinder.cc.
References utl::ConsecutiveEnumFactory< EnumType, last, tags, NoConversionPolicy, first >::Create(), ERROR, io::eSuccess, fwk::CentralConfig::GetInstance(), fwk::CentralConfig::GetTopBranch(), INFO, Likelihood(), utl::LoadConfig(), and utl::m.
|
inlineinherited |
Definition at line 95 of file VModule.h.
References fwk::VModule::fStopwatch, and utl::Stopwatch::Reset().
|
private |
|
virtual |
Run: invoked once per event.
This method is for things that should be done once per event {You must override this method in your concrete module}
Implements fwk::VModule.
Definition at line 147 of file MdLDFFinder.cc.
References fwk::LocalCoordinateSystemConstructor< Policy >::Create(), DEBUGLOG, utl::deg, SdMonteCarloPropagatorKVI::eBeta, SdHorizontalReconstructionNS::eCoreX, SdHorizontalReconstructionNS::eCoreY, ERROR, SdMonteCarloPropagatorKVI::eShowerSize, io::eSuccess, evt::ShowerSRecData::GetAxis(), evt::ShowerSRecData::GetCorePosition(), evt::Event::GetRecShower(), utl::BasicVector< HepVector >::GetTheta(), utl::BasicVector< HepVector >::GetX(), utl::BasicVector< HepVector >::GetY(), utl::BasicVector< HepVector >::GetZ(), evt::Event::HasMEvent(), evt::ShowerMRecData::HasMLDF(), evt::ShowerRecData::HasMRecShower(), evt::Event::HasRecShower(), INFO, evt::ShowerMRecData::MakeMLDF(), evt::ShowerMRecData::SetLdfReconstructed(), evt::ShowerMRecData::SetMLDFChi2(), evt::ShowerMRecData::SetMLDFLikelihood(), evt::ShowerMRecData::SetReferenceAxis(), evt::ShowerMRecData::SetReferenceCorePosition(), and evt::ShowerMRecData::SetReferenceDistance().
|
inlineinherited |
Definition at line 98 of file VModule.h.
References fwk::VModule::fStopwatch, fwk::VModule::Run(), utl::Stopwatch::Start(), and utl::Stopwatch::Stop().
Referenced by fwk::RunController::DoNextInSequence().
|
private |
Fill the minimizer with the candidate modules from the event No efforr is made hare that the statuses of counters and modules are correct. This has to be checked in the event selector.
Definition at line 571 of file MdLDFFinder.cc.
References mevt::MEvent::CountersBegin(), and mevt::MEvent::CountersEnd().
|
private |
Definition at line 552 of file MdLDFFinder.cc.
References mevt::MEvent::CountersBegin(), and mevt::MEvent::CountersEnd().
|
private |
Definition at line 600 of file MdLDFFinder.cc.
References fwk::LocalCoordinateSystemConstructor< Policy >::Create(), utl::cross(), utl::BasicVector< HepVector >::GetCosTheta(), mevt::Counter::GetId(), det::DetectorComponent< C, ManagerProvider >::GetId(), utl::AxialVector::GetMag(), mdet::Counter::GetModule(), det::MPositionable< Config >::GetPosition(), mevt::Counter::ModulesBegin(), and mevt::Counter::ModulesEnd().
|
private |
For beta parameterization: beta(theta) = a0 + a1 * sec(theta) + a2 * sec^2(theta)
Definition at line 148 of file MdLDFFinder.h.
|
private |
Definition at line 149 of file MdLDFFinder.h.
|
private |
Definition at line 150 of file MdLDFFinder.h.
|
private |
Definition at line 141 of file MdLDFFinder.h.
|
private |
Definition at line 142 of file MdLDFFinder.h.
|
private |
Definition at line 143 of file MdLDFFinder.h.
|
private |
Definition at line 135 of file MdLDFFinder.h.
|
private |
Definition at line 134 of file MdLDFFinder.h.
|
private |
Definition at line 159 of file MdLDFFinder.h.
|
protectedinherited |
Definition at line 123 of file VModule.h.
Referenced by RdChannelASCIINoiseImporterRD::RdChannelASCIINoiseImporterRD::Init(), Rd2dLDFFitter::Rd2dLDFFitter::Init(), RdChannelNoiseImporter_AERA::RdChannelNoiseImporter_AERA::Init(), and Rd2dLDFFitter::Rd2dLDFFitter::Run().
|
private |
Object performing the LDF and MinMethod evaluation.
Definition at line 169 of file MdLDFFinder.h.
|
private |
LDF and Minimization Method Types.
Definition at line 164 of file MdLDFFinder.h.
|
private |
Definition at line 138 of file MdLDFFinder.h.
|
private |
Definition at line 170 of file MdLDFFinder.h.
|
private |
Definition at line 165 of file MdLDFFinder.h.
|
private |
Definition at line 152 of file MdLDFFinder.h.
|
private |
Definition at line 157 of file MdLDFFinder.h.
|
private |
Definition at line 154 of file MdLDFFinder.h.
|
private |
Definition at line 139 of file MdLDFFinder.h.
|
private |
Definition at line 156 of file MdLDFFinder.h.
|
private |
Definition at line 153 of file MdLDFFinder.h.
|
static |
Tags for the types of LDF.
Definition at line 43 of file MdLDFFinder.h.
|
static |
Tags for the types of MinMethod.
Definition at line 52 of file MdLDFFinder.h.
|
private |
Definition at line 176 of file MdLDFFinder.h.
|
private |
Make detector data and coordinate system available to all methods.
Definition at line 175 of file MdLDFFinder.h.