58 theMass(config.getParameter<double>(
"ParticleMass")) {
59 edm::LogInfo(
"Alignment") <<
"@SUB=DualTrajectoryFactory"
72 edm::LogWarning(
"Alignment") <<
"@SUB=DualTrajectoryFactory::trajectories"
74 <<
": You should probably use the DualBzeroTrajectoryFactory\n"
75 <<
"or fix this code to switch automatically as the ReferenceTrajectoryFactory does.";
78 ConstTrajTrackPairCollection::const_iterator itTracks = tracks.begin();
80 while (itTracks != tracks.end()) {
90 trajectories.push_back(ptr);
106 if (tracks.size() != external.size()) {
108 <<
"@SUB=DualTrajectoryFactory::trajectories"
109 <<
"Inconsistent input:\n"
110 <<
"\tnumber of tracks = " << tracks.size() <<
"\tnumber of external predictions = " << external.size();
116 edm::LogWarning(
"Alignment") <<
"@SUB=DualTrajectoryFactory::trajectories"
118 <<
": You should probably use the DualBzeroTrajectoryFactory\n"
119 <<
"or fix this code to switch automatically as the ReferenceTrajectoryFactory does.";
122 ConstTrajTrackPairCollection::const_iterator itTracks = tracks.begin();
123 ExternalPredictionCollection::const_iterator itExternal = external.begin();
125 while (itTracks != tracks.end()) {
129 if ((*itExternal).isValid()) {
143 ptr->setParameterErrors(externalParamErrors);
144 trajectories.push_back(ptr);
152 trajectories.push_back(ptr);
170 Trajectory::DataContainer::iterator itM;
172 for (itM = allTrajMeas.begin(); itM != allTrajMeas.end(); itM++) {
174 usedTrajMeas.push_back(*itM);
177 unsigned int iMeas = 0;
178 unsigned int nMeas = usedTrajMeas.size();
179 unsigned int nRefStateMeas = nMeas / 2;
181 for (itM = usedTrajMeas.begin(); itM != usedTrajMeas.end(); itM++, iMeas++) {
184 if (iMeas < nRefStateMeas) {
186 }
else if (iMeas > nRefStateMeas) {
189 if ((*itM).updatedState().isValid()) {
190 input.
refTsos = (*itM).updatedState();
211 const std::pair<TrajectoryStateOnSurface, double> tsosWithPath = propagator.
propagateWithPath(external, surface);
212 return tsosWithPath.first;
const TrajectoryStateOnSurface propagateExternal(const TrajectoryStateOnSurface &external, const Surface &surface, const MagneticField *magField) const
const DualTrajectoryInput referenceStateAndRecHits(const ConstTrajTrackPair &track) const
MaterialEffects materialEffects(void) const
virtual GlobalVector inTesla(const GlobalPoint &gp) const =0
Field value ad specified global point, in Tesla.
Global3DPoint GlobalPoint
virtual const Trajectory::DataContainer orderedTrajectoryMeasurements(const Trajectory &trajectory) const
AlignmentAlgorithmBase::ConstTrajTrackPair ConstTrajTrackPair
auto const & tracks
cannot be loose
bool useRecHit(const TransientTrackingRecHit::ConstRecHitPointer &hitPtr) const
static std::string const input
bool getData(T &iHolder) const
const SurfaceType & surface() const
std::vector< TrajectoryMeasurement > DataContainer
std::pair< TrajectoryStateOnSurface, double > propagateWithPath(const FreeTrajectoryState &fts, const Plane &plane) const override
propagation to plane with path length
std::shared_ptr< TrackingRecHit const > ConstRecHitPointer
const bool allowZeroMaterial_
const edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > m_MagFieldToken
const AlgebraicSymMatrix55 & matrix() const
const LocalTrajectoryError & localError() const
std::vector< ConstRecHitPointer > ConstRecHitContainer
Log< level::Info, false > LogInfo
const ReferenceTrajectoryCollection trajectories(const edm::EventSetup &setup, const ConstTrajTrackPairCollection &tracks, const reco::BeamSpot &beamSpot) const override
Produce the reference trajectories.
AlignmentAlgorithmBase::ConstTrajTrackPairCollection ConstTrajTrackPairCollection
DualTrajectoryFactory * clone() const override
~DualTrajectoryFactory() override
tuple config
parse the configuration file
PropagationDirection propagationDirection(void) const
CLHEP::HepSymMatrix AlgebraicSymMatrix
std::vector< TrajectoryStateOnSurface > ExternalPredictionCollection
#define DEFINE_EDM_PLUGIN(factory, type, name)
Log< level::Warning, false > LogWarning
A factory that produces instances of class ReferenceTrajectory from a given TrajTrackPairCollection.
DualTrajectoryFactory(const edm::ParameterSet &config, edm::ConsumesCollector &iC)
std::vector< ReferenceTrajectoryPtr > ReferenceTrajectoryCollection