APRILContent
Algorithm of Particle Reconstruction for ILC - implementation with PandoraSDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations
APRILContent.h
Go to the documentation of this file.
1 /*
3  *
4  * APRILContent.h header template automatically generated by a class generator
5  * Creation date : ven. mars 20 2015
6  *
7  * This file is part of APRILContent libraries.
8  *
9  * APRILContent is free software: you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation, either version 3 of the License, or
12  * (at your option) any later version.
13  * based upon these libraries are permitted. Any copy of these libraries
14  * must include this copyright notice.
15  *
16  * APRILContent is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19  * GNU General Public License for more details.
20  *
21  * You should have received a copy of the GNU General Public License
22  * along with APRILContent. If not, see <http://www.gnu.org/licenses/>.
23  *
24  * @author Remi Ete
25  * @copyright CNRS , IPNL
26  */
27 
28 #ifndef APRIL_CONTENT_H
29 #define APRIL_CONTENT_H 1
30 
31 // multi-threading option
32 #ifdef APRIL_PARALLEL
33 #include <omp.h>
34 #endif
35 
36 #include "Api/PandoraApi.h"
37 #include "Pandora/PandoraInternal.h"
40 
59 
66 
78 
82 
84 
88 
94 
99 
107 
133 
141 
156 
161 {
162 public:
163 
164 #define APRIL_ALGORITHM_LIST(d) \
165  d("PerfectParticleFlow", april_content::PerfectParticleFlowAlgorithm::Factory) \
166  d("PerfectClustering", april_content::PerfectClusteringAlgorithm::Factory) \
167  d("PerfectClusteringNew", april_content::PerfectClusteringAlgorithmNew::Factory) \
168  d("PerfectHitCorrection", april_content::PerfectHitCorrectionAlgorithm::Factory) \
169  d("PerfectFragmentRemoval", april_content::PerfectFragmentRemovalAlgorithm::Factory) \
170  d("PerfectIsoHitRemoval", april_content::PerfectIsoHitRemovalAlgorithm::Factory) \
171  d("IsoHitRemoval", april_content::IsoHitRemovalAlgorithm::Factory) \
172  d("IsoHitClustering", april_content::IsoHitClusteringAlgorithm::Factory) \
173  d("FragmentsFromIsoHitsMerging", april_content::FragmentsFromIsoHitsMergingAlgorithm::Factory) \
174  d("PerfectNeutralHitRecovery", april_content::PerfectNeutralHitRecoveryAlgorithm::Factory) \
175  d("PerfectChargedHitRecovery", april_content::PerfectChargedHitRecoveryAlgorithm::Factory) \
176  d("PerfectChargedClusterSeparation", april_content::PerfectChargedClusterSeparationAlgorithm::Factory) \
177  d("PerfectPfoCreation", april_content::PerfectPfoCreationAlgorithm::Factory) \
178  d("SimplePfoTest", april_content::SimplePfoTestAlgorithm::Factory) \
179  d("SemiPerfectPfoCreation", april_content::SemiPerfectPfoCreationAlgorithm::Factory) \
180  d("CheatingTrackToClusterMatching", april_content::CheatingTrackToClusterMatching::Factory) \
181  d("APRILClustering", april_content::APRILClusteringAlgorithm::Factory) \
182  d("CheatingClusterCleaning", april_content::CheatingClusterCleaningAlgorithm::Factory) \
183  d("CheatingClusterMerging", april_content::CheatingClusterMergingAlgorithm::Factory) \
184  d("CheatingClusterMergingNew", april_content::CheatingClusterMergingNewAlgorithm::Factory) \
185  d("CheatingHitRecovery", april_content::CheatingHitRecoveryAlgorithm::Factory) \
186  d("CheatingParticleID", april_content::CheatingParticleIDAlgorithm::Factory) \
187  d("ClusteringParent", april_content::ClusteringParentAlgorithm::Factory) \
188  d("SimpleRegionClustering", april_content::SimpleRegionClusteringAlgorithm::Factory) \
189  d("VisualMonitoring", april_content::VisualMonitoringAlgorithm::Factory) \
190  d("PerformanceMonitoring", april_content::PerformanceMonitoringAlgorithm::Factory) \
191  d("SingleParticleMonitoring", april_content::SingleParticleMonitoringAlgorithm::Factory) \
192  d("FinalParticleId", april_content::FinalParticleIdAlgorithm::Factory) \
193  d("PhotonReconstruction", april_content::PhotonReconstructionAlgorithm::Factory) \
194  d("SingleClusterId", april_content::SingleClusterIdAlgorithm::Factory) \
195  d("PfoCreation", april_content::PfoCreationAlgorithm::Factory) \
196  d("EnergyExcessReclustering", april_content::EnergyExcessReclusteringAlgorithm::Factory) \
197  d("MissingEnergyReclustering", april_content::MissingEnergyReclusteringAlgorithm::Factory) \
198  d("SplitTrackReclustering", april_content::SplitTrackReclusteringAlgorithm::Factory) \
199  d("ForceSplitTrackAssociations", april_content::ForceSplitTrackAssociationsAlg::Factory) \
200  d("TopologicalAssociationParent", april_content::TopologicalAssociationParentAlgorithm::Factory) \
201  d("PointingClusterAssociation", april_content::PointingClusterAssociationAlgorithm::Factory) \
202  d("PointingClusterAssociationNew", april_content::PointingClusterAssociationNewAlgorithm::Factory) \
203  d("ClustersMerging", april_content::ClustersMergingAlgorithm::Factory) \
204  d("MatchTrackWithStartingCluster", april_content::MatchTrackWithStartingClusterAlgorithm::Factory) \
205  d("ClusterFromTrackMerging", april_content::ClusterFromTrackMergingAlgorithm::Factory) \
206  d("ClusterFromTrackMerging2", april_content::ClusterFromTrackMergingAlgorithm2::Factory) \
207  d("ClusterFromTrackMerging3", april_content::ClusterFromTrackMergingAlgorithm3::Factory) \
208  d("ChargedFragmentsMerging", april_content::ChargedFragmentsMergingAlgorithm::Factory) \
209  d("ChargedFragmentsMerging2", april_content::ChargedFragmentsMergingAlgorithm2::Factory) \
210  d("ChargedFragmentsMerging3", april_content::ChargedFragmentsMergingAlgorithm3::Factory) \
211  d("ClusterFromTrackMerging4", april_content::ClusterFromTrackMergingAlgorithm4::Factory) \
212  d("ClusterFromTrackMerging5", april_content::ClusterFromTrackMergingAlgorithm5::Factory) \
213  d("NeutralFragmentMerging", april_content::NeutralFragmentMergingAlgorithm::Factory) \
214  d("NearbyFragmentsMerging", april_content::NearbyFragmentsMergingAlgorithm::Factory) \
215  d("ClosebySeedMerging", april_content::ClosebySeedMergingAlgorithm::Factory) \
216  d("ClusterFragmentMerging", april_content::ClusterFragmentMergingAlgorithm::Factory) \
217  d("SurroundingHitsMerging", april_content::SurroundingHitsMergingAlgorithm::Factory) \
218  d("NearbyTrackPhotonRemoval", april_content::NearbyTrackPhotonRemovalAlg::Factory) \
219  d("MipFragmentMerging", april_content::MipFragmentMergingAlg::Factory) \
220  d("FragmentRemoval", april_content::FragmentRemovalAlgorithm::Factory) \
221  d("FragmentsFinding", april_content::FragmentsFindingAlgorithm::Factory) \
222  d("PhotonClean", april_content::PhotonCleanAlgorithm::Factory) \
223  d("ConeBasedMerging", april_content::ConeBasedMergingAlgorithm::Factory) \
224  d("MainFragmentRemoval", april_content::MainFragmentRemovalAlgorithm::Factory) \
225  d("TrackClusterAssociationMVA", april_content::TrackClusterAssociationMVAAlgorithm::Factory) \
226  d("UnassociatedTrackRecovery", april_content::UnassociatedTrackRecoveryAlg::Factory) \
227  d("TrackClusterAssociation", april_content::TrackClusterAssociationAlgorithm::Factory) \
228  d("LoopingTrackAssociation", april_content::LoopingTrackAssociationAlgorithm::Factory) \
229  d("TrackRecovery", april_content::TrackRecoveryAlgorithm::Factory) \
230  d("TrackRecoveryHelix", april_content::TrackRecoveryHelixAlgorithm::Factory) \
231  d("TrackRecoveryInteractions", april_content::TrackRecoveryInteractionsAlgorithm::Factory) \
232  d("EventPreparation", april_content::EventPreparationAlgorithm::Factory) \
233  d("ClusterPreparation", april_content::ClusterPreparationAlgorithm::Factory) \
234  d("TrackPreparation", april_content::TrackPreparationAlgorithm::Factory) \
235  d("CaloHitListMerging", april_content::InputObjectListMergingAlgorithm<pandora::CaloHitList>::Factory) \
236  d("TrackListMerging", april_content::InputObjectListMergingAlgorithm<pandora::TrackList>::Factory) \
237  d("MCParticleListMerging", april_content::InputObjectListMergingAlgorithm<pandora::MCParticleList>::Factory) \
238  d("PfoListMerging", april_content::AlgorithmObjectListMergingAlgorithm<pandora::ParticleFlowObject>::Factory) \
239  d("ClusterListMerging", april_content::AlgorithmObjectListMergingAlgorithm<pandora::Cluster>::Factory) \
240  d("VertexListMerging", april_content::AlgorithmObjectListMergingAlgorithm<pandora::Vertex>::Factory) \
241  d("ListChanging", april_content::ListChangingAlgorithm::Factory) \
242  d("AlgorithmConfiguration", april_content::AlgorithmConfiguration::Factory) \
243  d("CaloHitPreparation", april_content::CaloHitPreparationAlgorithm::Factory) \
244  d("CaloHitTiming", april_content::CaloHitTimingAlgorithm::Factory) \
245  d("ClusterCheck", april_content::ClusterCheckAlgorithm::Factory) \
246  d("ClusterPurity", april_content::ClusterPurityAlgorithm::Factory) \
247  d("ClusterEfficiency", april_content::ClusterEfficiencyAlgorithm::Factory) \
248  d("IsolatedHitClustering", april_content::IsolatedHitClusteringAlgorithm::Factory) \
249  d("NearbyHitRecovery", april_content::NearbyHitRecoveryAlgorithm::Factory) \
250  d("LoadEMCluster", april_content::LoadEMClusterAlgorithm::Factory)
251 
252 
253 #define APRIL_ALGORITHM_TOOL_LIST(d) \
254  d("ConnectorCleaning", april_content::ConnectorCleaningTool::Factory) \
255  d("ConnectorSeeding", april_content::ConnectorSeedingTool::Factory) \
256  d("ConnectorPlus", april_content::ConnectorPlusTool::Factory) \
257  d("NearbyHitsConnecting", april_content::NearbyHitsConnectingTool::Factory) \
258  d("TrackDrivenSeeding", april_content::TrackDrivenSeedingTool::Factory) \
259  d("ConnectorAlignment", april_content::ConnectorAlignmentTool::Factory) \
260  d("CaloHitMerging", april_content::CaloHitMergingTool::Factory)
261 
262 #define APRIL_PARTICLE_ID_LIST(d) \
263  d("APRILEmShowerId", april_content::APRILParticleIdPlugins::APRILEmShowerId) \
264  d("APRILPhotonId", april_content::APRILParticleIdPlugins::APRILPhotonId) \
265  d("APRILElectronId", april_content::APRILParticleIdPlugins::APRILElectronId) \
266  d("APRILMuonId", april_content::APRILParticleIdPlugins::APRILMuonId)
267 
268 
274  static pandora::StatusCode RegisterAlgorithms(const pandora::Pandora &pandora);
275 
281  static pandora::StatusCode RegisterAPRILPseudoLayerPlugin(const pandora::Pandora &pandora);
282  static pandora::StatusCode RegisterAPRILShowerProfilePlugin(const pandora::Pandora &pandora);
283 
292  static pandora::StatusCode RegisterBFieldPlugin(const pandora::Pandora &pandora, const float innerBField, const float muonBarrelBField,
293  const float muonEndCapBField);
294 
300  static pandora::StatusCode RegisterEnergyCorrections(const pandora::Pandora &pandora);
301 
307  static pandora::StatusCode RegisterParticleIds(const pandora::Pandora &pandora);
308 };
309 
310 //------------------------------------------------------------------------------------------------------------------------------------------
311 //------------------------------------------------------------------------------------------------------------------------------------------
312 
313 inline pandora::StatusCode APRILContent::RegisterAlgorithms(const pandora::Pandora &pandora)
314 {
315  APRIL_ALGORITHM_LIST(PANDORA_REGISTER_ALGORITHM);
316  APRIL_ALGORITHM_TOOL_LIST(PANDORA_REGISTER_ALGORITHM_TOOL);
317 
318  return pandora::STATUS_CODE_SUCCESS;
319 }
320 
321 //------------------------------------------------------------------------------------------------------------------------------------------
322 
323 inline pandora::StatusCode APRILContent::RegisterAPRILPseudoLayerPlugin(const pandora::Pandora &pandora)
324 {
325  return PandoraApi::SetPseudoLayerPlugin(pandora, new april_content::APRILPseudoLayerPlugin());
326 }
327 
328 inline pandora::StatusCode APRILContent::RegisterAPRILShowerProfilePlugin(const pandora::Pandora &pandora)
329 {
330  return PandoraApi::SetShowerProfilePlugin(pandora, new april_content::APRILShowerProfilePlugin());
331 }
332 
333 //------------------------------------------------------------------------------------------------------------------------------------------
334 
335 inline pandora::StatusCode APRILContent::RegisterBFieldPlugin(const pandora::Pandora &pandora, const float innerBField,
336  const float muonBarrelBField, const float muonEndCapBField)
337 {
338  return PandoraApi::SetBFieldPlugin(pandora, new april_content::APRILBFieldPlugin(innerBField, muonBarrelBField, muonEndCapBField));
339 }
340 
341 //------------------------------------------------------------------------------------------------------------------------------------------
342 
343 inline pandora::StatusCode APRILContent::RegisterEnergyCorrections(const pandora::Pandora &pandora)
344 {
345  /* PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
346  "SdhcalQuadraticEnergyFunction", pandora::HADRONIC, new april_content::SdhcalQuadraticEnergyFunction));
347 
348  PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
349  "SdhcalQuadraticEnergyFunction", pandora::ELECTROMAGNETIC, new april_content::SdhcalQuadraticEnergyFunction));
350 
351  PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
352  "AnalogicEnergyFunction", pandora::HADRONIC, new april_content::AnalogicEnergyFunction));
353 
354  PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
355  "AnalogicEnergyFunction", pandora::ELECTROMAGNETIC, new april_content::AnalogicEnergyFunction));
356 
357  PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
358  "BarrelGapEnergyFunction", pandora::HADRONIC, new april_content::BarrelGapEnergyFunction));
359 
360  PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
361  "ThetaEnergyFunction", pandora::HADRONIC, new april_content::ThetaEnergyFunction));
362  */
363  /* PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
364  "ThetaNHitFunction", pandora::HADRONIC, new april_content::ThetaNHitFunction()));
365 
366  PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
367  "PhiNHitFunction", pandora::HADRONIC, new april_content::PhiNHitFunction()));
368  */
369  /* PANDORA_RETURN_RESULT_IF(pandora::STATUS_CODE_SUCCESS, !=, PandoraApi::RegisterEnergyCorrectionPlugin(pandora,
370  "CleanClusters", pandora::HADRONIC, new april_content::CleanCluster()));
371  */
372  return pandora::STATUS_CODE_SUCCESS;
373 }
374 
375 //------------------------------------------------------------------------------------------------------------------------------------------
376 
377 pandora::StatusCode APRILContent::RegisterParticleIds(const pandora::Pandora &pandora)
378 {
379  APRIL_PARTICLE_ID_LIST(PANDORA_REGISTER_PARTICLE_ID);
380 
381  return pandora::STATUS_CODE_SUCCESS;
382 }
383 
384 
385 #endif // APRIL_CONTENT_H
Header file for the cheating cluster cleaning algorithm class.
Header file for the cheating cluster cleaning algorithm class.
Header file for the cheating cluster cleaning algorithm class.
Header file for the looping track association algorithm class.
Header file for the perfect particle flow algorithm class.
Header file for the cheating clustering algorithm class.
static pandora::StatusCode RegisterBFieldPlugin(const pandora::Pandora &pandora, const float innerBField, const float muonBarrelBField, const float muonEndCapBField)
Register the b field plugin (note user side configuration) with pandora.
Definition: APRILContent.h:335
Header file for the cheating cluster cleaning algorithm class.
Header file for the cheating clustering algorithm class.
APRILBFieldPlugin class.
Definition: APRILBFieldPlugin.h:38
Header file for the perfect particle flow algorithm class.
APRILPseudoLayerPlugin class.
Definition: APRILPseudoLayerPlugin.h:41
APRILShowerProfilePlugin class.
Definition: ShowerProfilePlugin.h:18
Header file for the cheating track to cluster matching algorithm class.
Header file for the cheating clustering algorithm class.
Header file for the track recovery interactions algorithm class.
Header file for the shower profile plugin class.
Header file for the cheating clustering algorithm class.
Header file for the force split track associations algorithm class.
Header file for the perfect particle flow algorithm class.
APRILContent class used to register april algorithms and plugins.
Definition: APRILContent.h:160
Header file for the track-cluster association algorithm class.
Header file for the cone based merging algorithm class.
Header file for the cheating clustering algorithm class.
Header file for the main fragment removal algorithm class.
static pandora::StatusCode RegisterAlgorithms(const pandora::Pandora &pandora)
Register all the april algorithms with pandora.
Definition: APRILContent.h:313
static pandora::StatusCode RegisterEnergyCorrections(const pandora::Pandora &pandora)
Register the energy corrections with pandora.
Definition: APRILContent.h:343
Header file for the cheating cluster cleaning algorithm class.
static pandora::StatusCode RegisterParticleIds(const pandora::Pandora &pandora)
Register april particle id functions.
Definition: APRILContent.h:377
Header file for the cheating clustering algorithm class.
Header file for the cheating clustering algorithm class.
static pandora::StatusCode RegisterAPRILPseudoLayerPlugin(const pandora::Pandora &pandora)
Register pseudo layer plugin with pandora.
Definition: APRILContent.h:323
Header file for the track recovery algorithm class.
Header file for the cheating particle id algorithm class.
Header file for the track recovery helix algorithm class.