Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
src
TrackingTools
GsfTracking
src
GsfMultiStateUpdator.cc
Go to the documentation of this file.
1
#include "
TrackingTools/GsfTracking/interface/GsfMultiStateUpdator.h
"
2
3
#include "
TrackingTools/KalmanUpdators/interface/KFUpdator.h
"
4
#include "
TrackingTools/PatternTools/interface/MeasurementExtractor.h
"
5
#include "
TrackingTools/TransientTrackingRecHit/interface/TransientTrackingRecHit.h
"
6
#include "
DataFormats/GeometrySurface/interface/BoundPlane.h
"
7
#include "
TrackingTools/TrajectoryState/interface/TrajectoryStateOnSurface.h
"
8
#include "
TrackingTools/GsfTools/interface/BasicMultiTrajectoryState.h
"
9
#include "
TrackingTools/GsfTracking/interface/PosteriorWeightsCalculator.h
"
10
#include "
TrackingTools/GsfTools/interface/MultiTrajectoryStateAssembler.h
"
11
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
12
13
TrajectoryStateOnSurface
GsfMultiStateUpdator::update
(
const
TrajectoryStateOnSurface
& tsos,
14
const
TransientTrackingRecHit
& aRecHit)
const
{
15
16
std::vector<TrajectoryStateOnSurface> predictedComponents = tsos.
components
();
17
if
(predictedComponents.empty()) {
18
edm::LogError
(
"GsfMultiStateUpdator"
) <<
"Trying to update trajectory state with zero components! "
;
19
return
TrajectoryStateOnSurface
();
20
}
21
22
std::vector<double>
weights
=
PosteriorWeightsCalculator
(predictedComponents).
weights
(aRecHit);
23
if
( weights.empty() ) {
24
edm::LogError
(
"GsfMultiStateUpdator"
) <<
" no weights could be retreived. invalid updated state !."
;
25
return
TrajectoryStateOnSurface
();
26
}
27
28
MultiTrajectoryStateAssembler
result
;
29
30
int
i
= 0;
31
for
(std::vector<TrajectoryStateOnSurface>::const_iterator iter = predictedComponents.begin();
32
iter != predictedComponents.end(); iter++) {
33
TrajectoryStateOnSurface
updatedTSOS =
KFUpdator
().update(*iter, aRecHit);
34
if
(updatedTSOS.
isValid
()){
35
result.
addState
(
TrajectoryStateOnSurface
(updatedTSOS.
localParameters
(),
36
updatedTSOS.
localError
(), updatedTSOS.
surface
(),
37
&(tsos.
globalParameters
().
magneticField
()),
38
(*iter).surfaceSide(), weights[
i
]));
39
i++;
40
}
41
else
{
42
edm::LogError
(
"GsfMultiStateUpdator"
) <<
"one of the KF updated state is invalid. skipping."
;
43
}
44
45
}
46
47
return
result.
combinedState
();
48
}
KFUpdator
i
int i
Definition:
DBlmapReader.cc:9
MessageLogger.h
PosteriorWeightsCalculator
Definition:
PosteriorWeightsCalculator.h:13
TrajectoryStateOnSurface::localParameters
const LocalTrajectoryParameters & localParameters() const
Definition:
TrajectoryStateOnSurface.h:168
MultiTrajectoryStateAssembler::addState
void addState(const TrajectoryStateOnSurface)
Definition:
MultiTrajectoryStateAssembler.cc:33
BasicMultiTrajectoryState.h
GsfMultiStateUpdator.h
TrajectoryStateOnSurface
Definition:
TrajectoryStateOnSurface.h:15
TransientTrackingRecHit.h
edm::LogError
Definition:
MessageLogger.h:164
TrajectoryStateOnSurface::surface
const SurfaceType & surface() const
Definition:
TrajectoryStateOnSurface.h:183
MultiTrajectoryStateAssembler.h
KFUpdator.h
query.result
tuple result
Definition:
query.py:137
BoundPlane.h
TrajectoryStateOnSurface::localError
const LocalTrajectoryError & localError() const
Definition:
TrajectoryStateOnSurface.h:180
PosteriorWeightsCalculator::weights
std::vector< double > weights(const TransientTrackingRecHit &tsos) const
Create random state.
Definition:
PosteriorWeightsCalculator.cc:9
TrajectoryStateOnSurface::globalParameters
const GlobalTrajectoryParameters & globalParameters() const
Definition:
TrajectoryStateOnSurface.h:141
TransientTrackingRecHit
Definition:
TransientTrackingRecHit.h:21
create_public_pileup_plots.weights
list weights
Definition:
create_public_pileup_plots.py:205
PosteriorWeightsCalculator.h
TrajectoryStateOnSurface.h
TrajectoryStateOnSurface::isValid
bool isValid() const
Definition:
TrajectoryStateOnSurface.h:123
GlobalTrajectoryParameters::magneticField
const MagneticField & magneticField() const
Definition:
GlobalTrajectoryParameters.h:111
MultiTrajectoryStateAssembler
Definition:
MultiTrajectoryStateAssembler.h:13
TrajectoryStateOnSurface::components
std::vector< TrajectoryStateOnSurface > components() const
Definition:
TrajectoryStateOnSurface.h:193
MultiTrajectoryStateAssembler::combinedState
TrajectoryStateOnSurface combinedState()
Definition:
MultiTrajectoryStateAssembler.cc:94
MeasurementExtractor.h
GsfMultiStateUpdator::update
TrajectoryStateOnSurface update(const TrajectoryStateOnSurface &, const TransientTrackingRecHit &) const
Definition:
GsfMultiStateUpdator.cc:13
Generated for CMSSW Reference Manual by
1.8.5