Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4205 from ebrondol/DAF_CMSSW_7_1_0_pre8
Deterministic Annealing Filter for track reconstruction
- Loading branch information
Showing
56 changed files
with
2,658 additions
and
191 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<use name="DataFormats/GeometryVector"/> | ||
<use name="DataFormats/Math"/> | ||
<use name="DataFormats/TrackerRecHit2D"/> | ||
<use name="FWCore/Framework"/> | ||
<use name="FWCore/MessageLogger"/> | ||
<use name="FWCore/Utilities"/> | ||
<use name="RecoTracker/MeasurementDet"/> | ||
<use name="RecoTracker/TkDetLayers"/> | ||
<use name="RecoTracker/TransientTrackingRecHit"/> | ||
<use name="TrackingTools/DetLayers"/> | ||
<use name="TrackingTools/GeomPropagators"/> | ||
<use name="TrackingTools/KalmanUpdators"/> | ||
<use name="TrackingTools/MeasurementDet"/> | ||
<use name="TrackingTools/PatternTools"/> | ||
<use name="TrackingTools/TrajectoryState"/> | ||
<use name="TrackingTools/TransientTrackingRecHit"/> | ||
<use name="TrackingTools/TrackFitters"/> | ||
<export> | ||
<lib name="1"/> | ||
</export> | ||
|
85 changes: 85 additions & 0 deletions
85
RecoTracker/SiTrackerMRHTools/interface/GenericProjectedRecHit2D.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
#ifndef RECOTRACKER_TRANSIENTRACKINGRECHIT_GenericProjectedRecHit2D_H | ||
#define RECOTRACKER_TRANSIENTRACKINGRECHIT_GenericProjectedRecHit2D_H | ||
|
||
#include "TrackingTools/TransientTrackingRecHit/interface/TransientTrackingRecHit.h" | ||
#include "TrackingTools/TransientTrackingRecHit/interface/HelpertRecHit2DLocalPos.h" | ||
#include "TrackingTools/KalmanUpdators/interface/TrackingRecHitPropagator.h" | ||
|
||
class GenericProjectedRecHit2D : public TransientTrackingRecHit { | ||
public: | ||
|
||
GenericProjectedRecHit2D( const LocalPoint& pos, const LocalError& err, | ||
const GeomDet* det, const GeomDet* originaldet, | ||
const TransientTrackingRecHit::ConstRecHitPointer originalHit, | ||
const TrackingRecHitPropagator* propagator); | ||
|
||
virtual AlgebraicSymMatrix parametersError() const { | ||
return HelpertRecHit2DLocalPos().parError( localPositionError(), *det()); | ||
} | ||
|
||
//virtual ~GenericProjectedRecHit2D(){delete theOriginalTransientHit;} | ||
|
||
virtual AlgebraicVector parameters() const ; | ||
|
||
virtual LocalPoint localPosition() const {return theLp;} | ||
|
||
virtual LocalError localPositionError() const {return theLe;} | ||
|
||
virtual AlgebraicMatrix projectionMatrix() const {return theProjectionMatrix;} | ||
|
||
virtual DetId geographicalId() const {return det() ? det()->geographicalId() : DetId();} | ||
|
||
virtual int dimension() const {return theDimension;} | ||
|
||
//this hit lays on the original surface, NOT on the projection surface | ||
virtual const TrackingRecHit * hit() const { return theOriginalTransientHit->hit(); } | ||
|
||
virtual TrackingRecHit * cloneHit() const { return theOriginalTransientHit->cloneHit(); } | ||
|
||
virtual bool isValid() const{return true;} | ||
|
||
virtual std::vector<const TrackingRecHit*> recHits() const { | ||
//return theOriginalTransientHit->hit()->recHits(); | ||
return std::vector<const TrackingRecHit*>(); | ||
} | ||
|
||
virtual std::vector<TrackingRecHit*> recHits() { | ||
//should it do something different? | ||
return std::vector<TrackingRecHit*>(); | ||
} | ||
|
||
const TrackingRecHitPropagator* propagator() const {return thePropagator;} | ||
|
||
virtual bool canImproveWithTrack() const {return true;} | ||
|
||
const GeomDet* originalDet() const {return theOriginalDet;} | ||
|
||
static RecHitPointer build( const LocalPoint& pos, const LocalError& err, | ||
const GeomDet* det, const GeomDet* originaldet, | ||
const TransientTrackingRecHit::ConstRecHitPointer originalHit, | ||
const TrackingRecHitPropagator* propagator) { | ||
return RecHitPointer( new GenericProjectedRecHit2D( pos, err, det, originaldet, originalHit, propagator)); | ||
} | ||
|
||
RecHitPointer clone( const TrajectoryStateOnSurface& ts, const TransientTrackingRecHitBuilder*) const; | ||
|
||
private: | ||
|
||
const GeomDet* theOriginalDet; | ||
TransientTrackingRecHit::ConstRecHitPointer theOriginalTransientHit; | ||
LocalPoint theLp; | ||
LocalError theLe; | ||
AlgebraicMatrix theProjectionMatrix; | ||
const TrackingRecHitPropagator* thePropagator; | ||
//const TrackingRecHit* theOriginalHit; | ||
int theDimension; | ||
|
||
virtual GenericProjectedRecHit2D* clone() const { | ||
return new GenericProjectedRecHit2D(*this); | ||
} | ||
|
||
}; | ||
|
||
|
||
|
||
#endif |
56 changes: 56 additions & 0 deletions
56
RecoTracker/SiTrackerMRHTools/interface/GroupedDAFHitCollector.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
/** \class GroupedDAFHitCollector | ||
* Returns a collection of SiTrackerMultiRecHits and InvalidRecHits given a Trajectory. | ||
* Builds a SiTrackerMultiRecHit for each detGroup | ||
* (i.e. a group of detectors mutually exclusive for the track's crossing point) | ||
* | ||
* \author tropiano, genta | ||
* \review in May 2014 by brondolin | ||
*/ | ||
|
||
#ifndef SiTrackerMRHTools_GroupedDAFHitCollector_h | ||
#define SiTrackerMRHTools_GroupedDAFHitCollector_h | ||
|
||
#include "TrackingTools/MeasurementDet/interface/LayerMeasurements.h" | ||
#include "RecoTracker/SiTrackerMRHTools/interface/MultiRecHitCollector.h" | ||
#include <vector> | ||
|
||
class Propagator; | ||
class MeasurementEstimator; | ||
class MeasurementTracker; | ||
class SiTrackerMultiRecHitUpdator; | ||
|
||
class GroupedDAFHitCollector :public MultiRecHitCollector { | ||
|
||
public: | ||
explicit GroupedDAFHitCollector(const MeasurementTracker* measurementTracker, | ||
const SiTrackerMultiRecHitUpdator* updator, | ||
const MeasurementEstimator* est, | ||
const Propagator* propagator, | ||
const Propagator* reversePropagator, bool debug): | ||
MultiRecHitCollector(measurementTracker), theUpdator(updator), | ||
theEstimator(est), thePropagator(propagator), theReversePropagator(reversePropagator), debug_(debug){} | ||
|
||
|
||
virtual ~GroupedDAFHitCollector(){} | ||
|
||
virtual std::vector<TrajectoryMeasurement> recHits(const Trajectory&, | ||
const MeasurementTrackerEvent *theMT) const; | ||
|
||
const SiTrackerMultiRecHitUpdator* getUpdator() const {return theUpdator;} | ||
const MeasurementEstimator* getEstimator() const {return theEstimator;} | ||
const Propagator* getPropagator() const {return thePropagator;} | ||
const Propagator* getReversePropagator() const {return theReversePropagator;} | ||
|
||
private: | ||
void buildMultiRecHits(const std::vector<TrajectoryMeasurementGroup>& measgroup, | ||
std::vector<TrajectoryMeasurement>& result) const; | ||
|
||
const SiTrackerMultiRecHitUpdator* theUpdator; | ||
const MeasurementEstimator* theEstimator; | ||
const Propagator* thePropagator; | ||
const Propagator* theReversePropagator; | ||
const bool debug_; | ||
}; | ||
|
||
|
||
#endif |
39 changes: 39 additions & 0 deletions
39
RecoTracker/SiTrackerMRHTools/interface/MeasurementByLayerGrouper.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#ifndef SiTrackerMRHTools_MeasurementByLayerGrouper_H | ||
#define SiTrackerMRHTools_MeasurementByLayerGrouper_H | ||
|
||
class DetLayer; | ||
class TrajectoryMeasurement; | ||
class GeometricSearchTracker; | ||
|
||
#include <vector> | ||
#include <map> | ||
|
||
//groups the TrajectoryMeasurements on a layer by layer basis | ||
|
||
class MeasurementByLayerGrouper { | ||
|
||
private: | ||
|
||
typedef TrajectoryMeasurement TM; | ||
const GeometricSearchTracker* theGeomSearch; | ||
|
||
const DetLayer* getDetLayer(const TM& tm) const; | ||
|
||
public: | ||
|
||
explicit MeasurementByLayerGrouper(const GeometricSearchTracker* search = 0):theGeomSearch(search){}; | ||
|
||
std::vector<std::pair<const DetLayer*, std::vector<TM> > > operator()(const std::vector<TM>&) const; | ||
|
||
|
||
//to be ported later if needed | ||
/* | ||
vector<TM> | ||
operator()(const vector<pair<const DetLayer*, vector<TM> > >&) const; | ||
vector<pair<const DetLayer*, map<int, vector<TrajectoryMeasurement> > > > | ||
operator()(const map<int, vector<TM> >&) const; | ||
*/ | ||
|
||
}; | ||
#endif |
26 changes: 26 additions & 0 deletions
26
RecoTracker/SiTrackerMRHTools/interface/MultiRecHitCollector.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#ifndef SiTrackerMRHTools_MultiRecHitCollector_h | ||
#define SiTrackerMRHTools_MultiRecHitCollector_h | ||
|
||
#include "RecoTracker/MeasurementDet/interface/MeasurementTracker.h" | ||
#include <vector> | ||
|
||
class Trajectory; | ||
class TrajectoryMeasurement; | ||
|
||
class MultiRecHitCollector { | ||
|
||
public: | ||
MultiRecHitCollector(const MeasurementTracker* meas): theMeasurementTracker(meas){} | ||
|
||
virtual std::vector<TrajectoryMeasurement> recHits(const Trajectory&, const MeasurementTrackerEvent *theMTE) const = 0; | ||
|
||
const MeasurementTracker* getMeasurementTracker() const {return theMeasurementTracker;} | ||
|
||
|
||
private: | ||
const MeasurementTracker* theMeasurementTracker; | ||
|
||
}; | ||
|
||
#endif | ||
|
Oops, something went wrong.