89 produces<TrajectorySeedCollection>();
94 if (conf.
exists(
"hitMasks")) {
99 std::vector<std::string> layerStringList =
101 std::string layerBegin = *(layerStringList.cbegin());
103 for (
auto it = layerStringList.cbegin(); it < layerStringList.cend(); ++it) {
104 std::vector<TrackingLayer> trackingLayerList;
107 unsigned int nHitsPerSeed = 0;
108 while (pos != std::string::npos) {
109 pos = line.find(
'+');
112 trackingLayerList.push_back(layerSpec);
113 line = line.substr(pos + 1, std::string::npos);
116 if (it == layerStringList.cbegin()) {
119 throw cms::Exception(
"FastSimTracking") <<
"All allowed seed layer definitions must have same elements";
125 if (conf.
exists(
"seedFinderSelector")) {
146 const std::vector<bool>*
hitMasks =
nullptr;
150 hitMasks = &(*hitMasksHandle);
159 const auto&
regions = *hregions;
174 for (
unsigned icomb = 0; icomb < recHitCombinations->size(); ++icomb) {
178 std::vector<const FastTrackerRecHit*> seedHitCandidates;
179 for (
const auto& _hit : recHitCombination) {
183 seedHitCandidates.push_back(_hit.get());
194 std::vector<unsigned int> seedHitNumbers = seedFinder.
getSeed(seedHitCandidates);
197 if (seedHitNumbers.size() > 1) {
200 for (
unsigned iIndex = 0; iIndex < seedHitNumbers.size(); ++iIndex) {
201 seedHits.
push_back(seedHitCandidates[seedHitNumbers[iIndex]]->
clone());
211 seedHits.
size() >= 3 ? &seedHits[2] :
nullptr,
212 seedHits.
size() >= 4 ? &seedHits[3] :
nullptr));
void setRecHitCombinationIndex(edm::OwnVector< T > &recHits, int32_t icomb)
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
void produce(edm::Event &, const edm::EventSetup &) override
TrajectorySeedProducer(const edm::ParameterSet &conf)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< std::vector< bool > > hitMasksToken
#define DEFINE_FWK_MODULE(type)
constexpr bool isUninitialized() const noexcept
bool exists(std::string const ¶meterName) const
checks if a parameter exists
edm::EDGetTokenT< edm::OwnVector< TrackingRegion > > trackingRegionToken
constexpr std::array< uint8_t, layerIndexSize > layer
unsigned int nHitsPerSeed_
bool getData(T &iHolder) const
bool insert(const std::vector< DATA > &dataList)
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyESToken_
std::string measurementTrackerLabel
std::vector< TrajectorySeed > TrajectorySeedCollection
std::unique_ptr< SeedFinderSelector > seedFinderSelector
std::vector< unsigned int > getSeed(const std::vector< const FastTrackerRecHit * > &trackerRecHits) const
static TrackingLayer createFromString(std::string layerSpecification)
bool hitIsMasked(const FastTrackerRecHit *hit, const std::vector< bool > &hitMasks)
std::vector< FastTrackerRecHitRef > FastTrackerRecHitCombination
T getParameter(std::string const &) const
std::vector< std::vector< TrackingLayer > > seedingLayers
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
edm::EDGetTokenT< FastTrackerRecHitCombinationCollection > recHitCombinationsToken
void addHitSelector(SeedFinderSelector *seedFinderSelector, unsigned int nHits)
SeedingTree< TrackingLayer > _seedingTree
std::unique_ptr< SeedCreator > seedCreator