8#include <tracking/ckf/cdc/filters/paths/CDCfromEclPathTruthVarSet.h>
10#include <tracking/ckf/cdc/entities/CDCCKFState.h>
12#include <ecl/dataobjects/ECLShower.h>
13#include <mdst/dataobjects/MCParticle.h>
15#include <tracking/dataobjects/RecoTrack.h>
22 const auto& seed = path->front();
23 const auto* seedRecoTrack = seed.getSeed();
24 const auto* seedEclShower = seedRecoTrack->getRelated<
ECLShower>(
"ECLShowers");
29 std::vector<MCParticle*> daughterMCParticles;
30 if (seedMCParticle->getNDaughters() > 0) {
31 daughterMCParticles = seedMCParticle->getDaughters();
36 for (
auto const& state : *path) {
41 const auto wireHit = state.getWireHit();
42 const auto cdcHit = wireHit->getHit();
45 if (seedMCTrack != 0 && seedMCTrack == hitMCTrack) {
52 var<
named(
"daughters")>() = daughters;
53 var<
named(
"PDG")>() = seedMCParticle->getPDG();
56 var<
named(
"seed_p_truth")>() = seedMom.R();
57 var<
named(
"seed_theta_truth")>() = seedMom.Theta() * 180. / M_PI;
58 var<
named(
"seed_pt_truth")>() = seedMom.Rho();
59 var<
named(
"seed_pz_truth")>() = seedMom.Z();
60 var<
named(
"seed_px_truth")>() = seedMom.X();
61 var<
named(
"seed_py_truth")>() = seedMom.Y();
67 if (particleMCTrack) {
70 var<
named(
"mcTrackHits")>() = mcTrackHits;
virtual bool extract(const BaseCDCPathFilter::Object *path) override
Generate and assign the variables from the object.
Class to store ECL Showers.
ROOT::Math::XYZVector getMomentum() const
The method to get return ROOT::Math::XYZVector Momentum.
A Class to store the Monte Carlo particle information.
This is the Reconstruction Event-Data Model Track.
unsigned int getNumberOfCDCHits() const
Return the number of cdc hits.
T * getRelated(const std::string &name="", const std::string &namedRelation="") const
Get the object to or from which this object has a relation.
AObject Object
Type of the object to be analysed.
static constexpr int named(const char *name)
Getter for the index from the name.
Float_t & var()
Reference getter for the value of the ith variable. Static version.
Abstract base class for different kinds of events.