60 tTopoToken_(esConsumes()),
62 layersToKeep_(iConfig.getParameter<int32_t>(
"layersToKeep")),
63 insideOut_(iConfig.getParameter<
bool>(
"insideOut")),
64 debug_(iConfig.getUntrackedParameter<
bool>(
"debug",
false)),
65 refitter_(iConfig, consumesCollector()) {
66 produces<std::vector<TrajectorySeed>>();
81 auto out = std::make_unique<std::vector<TrajectorySeed>>();
82 unsigned int nsrc =
src->size();
93 const std::vector<TrajectoryMeasurement> &tms = traj.
front().measurements();
98 std::cout <<
"Considering muon of pt " <<
mu.pt() <<
", eta = " <<
mu.eta() <<
", phi = " <<
mu.phi()
101 <<
" to momentum, so will start from " << (fromInside ?
"inside" :
"outside") << std::endl;
106 std::cout <<
"IN state: subdetector = " << tin.
recHit()->geographicalId().subdetId() << std::endl;
109 std::cout <<
"OU state: subdetector = " << tou.
recHit()->geographicalId().subdetId() << std::endl;
113 int lastSubdet = 0, lastLayer = -1;
114 for (
int i = (fromInside ? 0 : tms.size() - 1),
115 end = (fromInside ? tms.size() : -1),
116 step = (fromInside ? +1 : -1),
121 hit = tms[
i].recHit()->hit();
123 std::cout <<
" considering hit " <<
i <<
": rechit on " << (
hit ?
hit->geographicalId().rawId() : -1)
127 int subdet =
hit->geographicalId().subdetId();
128 int lay = tTopo.
layer(
hit->geographicalId());
129 if (subdet != lastSubdet || lay != lastLayer) {
141 tsos = tms[
i].updatedState().
isValid()
142 ? tms[
i].updatedState()
143 : (
abs(
i -
end) <
abs(
i) ? tms[
i].forwardPredictedState() : tms[
i].backwardPredictedState());
145 std::cout <<
" hit : subdetector = " << tms[
i].recHit()->geographicalId().subdetId() << std::endl;
146 if (
hit->isValid()) {
147 std::cout <<
" global pos Rho " << tms[
i].recHit()->globalPosition().perp() <<
", Z "
148 << tms[
i].recHit()->globalPosition().z() << std::endl;
150 std::cout <<
" invalid tracking rec hit, so no global position" << std::endl;