86 produces<reco::TrackCollection>();
87 produces<TrackingRecHitCollection>();
88 produces<reco::TrackExtraCollection>();
95 seedsToken = consumes<edm::View<TrajectorySeed> >(seedsTag);
104 using namespace reco;
119 const auto&
seeds = *hseeds;
135 for (
size_t iSeed = 0; iSeed <
seeds.size(); ++iSeed) {
139 if (
seed.nHits() == 0) {
140 const Surface* deepCore_sruface = &geometry_->idToDet(
seed.startingState().detId())->specificSurface();
148 if (tsAtClosestApproachSeed.
isValid()) {
158 tracks->emplace_back(0., 0., vSeed1, pSeed, state.
charge(), seedPerigeeErrors.covarianceMatrix());
160 edm::LogVerbatim(
"SeedValidator") <<
"TrajectoryStateClosestToBeamLine not valid";
163 tracks->emplace_back(
168 tracks->back().appendHits(
seed.recHits().begin(),
seed.recHits().end(), ttopo);
170 size_t firsthitindex = rechits->size();
171 for (
auto const& recHit :
seed.recHits()) {
172 rechits->push_back(recHit);
177 trackextras->back().setHits(ref_rechits, firsthitindex, rechits->size() - firsthitindex);
180 tracks->back().setExtra(
TrackExtraRef(ref_trackextras, trackextras->size() - 1));
184 edm::LogInfo(
"SeedValidator") <<
"failed to create tracks from " << nfailed <<
" out of " <<
seeds.size()
Log< level::Info, true > LogVerbatim
edm::EDGetTokenT< reco::BeamSpot > beamSpotToken
const edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > mfToken_
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
TrackCharge charge() const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
std::vector< Track > TrackCollection
collection of Tracks
auto const & tracks
cannot be loose
edm::Ref< TrackExtraCollection > TrackExtraRef
persistent reference to a TrackExtra
~TrackFromSeedProducer() override
bool getData(T &iHolder) const
void addDefault(ParameterSetDescription const &psetDescription)
edm::EDGetTokenT< edm::View< TrajectorySeed > > seedsToken
FreeTrajectoryState const * freeState(bool withErrors=true) const
math::XYZPoint Point
point in the space
const edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > geoToken_
GlobalVector momentum() const
std::shared_ptr< TrackingRecHit const > RecHitPointer
RefProd< PROD > getRefBeforePut()
FTS const & trackStateAtPCA() const
Log< level::Info, false > LogInfo
GlobalPoint position() const
std::vector< TrackExtra > TrackExtraCollection
collection of TrackExtra objects
const edm::ESGetToken< TransientTrackingRecHitBuilder, TransientRecHitRecord > ttrhToken_
TrackFromSeedProducer(const edm::ParameterSet &)
T getParameter(std::string const &) const
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken_
PerigeeTrajectoryError ftsToPerigeeError(const FTS &originalFTS)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
math::XYZVector Vector
spatial vector
void produce(edm::StreamID, edm::Event &, const edm::EventSetup &) const override
math::Error< dimension >::type CovarianceMatrix
5 parameter covariance matrix