95 produces<TrajectorySeedCollection>();
99 if (conf.
exists(
"hitMasks"))
105 std::vector<std::string> layerStringList = conf.
getParameter<
edm::ParameterSet>(
"seedFinderSelector").getParameter<std::vector<std::string>>(
"layerList");
106 std::string layerBegin = *(layerStringList.cbegin());
108 for(
auto it=layerStringList.cbegin(); it < layerStringList.cend(); ++it)
110 std::vector<TrackingLayer> trackingLayerList;
113 unsigned int nHitsPerSeed = 0;
114 while (pos != std::string::npos)
119 trackingLayerList.push_back(layerSpec);
120 line=line.substr(pos+1,std::string::npos);
123 if(it==layerStringList.cbegin())
129 throw cms::Exception(
"FastSimTracking") <<
"All allowed seed layer definitions must have same elements";
135 if(conf.
exists(
"seedFinderSelector"))
162 const std::vector<bool> *
hitMasks =
nullptr;
167 hitMasks = &(*hitMasksHandle);
176 const auto& regions = *hregions;
193 for (
unsigned icomb=0; icomb<recHitCombinations->size(); ++icomb)
198 std::vector<const FastTrackerRecHit * > seedHitCandidates;
199 for (
const auto & _hit : recHitCombination )
205 seedHitCandidates.push_back(_hit.get());
209 for(
const auto& region: regions)
218 std::vector<unsigned int> seedHitNumbers =
seedFinder.getSeed(seedHitCandidates);
221 if (seedHitNumbers.size()>1)
226 for(
unsigned iIndex = 0;iIndex < seedHitNumbers.size();++iIndex)
228 seedHits.
push_back(seedHitCandidates[seedHitNumbers[iIndex]]->
clone());
240 seedHits.
size() >=3 ? &seedHits[2] :
nullptr,
void setRecHitCombinationIndex(edm::OwnVector< T > &recHits, int32_t icomb)
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
TrajectorySeedProducer(const edm::ParameterSet &conf)
def create(alignables, pedeDump, additionalData, outputFile, config)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< std::vector< bool > > hitMasksToken
#define DEFINE_FWK_MODULE(type)
bool exists(std::string const ¶meterName) const
checks if a parameter exists
edm::EDGetTokenT< edm::OwnVector< TrackingRegion > > trackingRegionToken
unsigned int nHitsPerSeed_
bool insert(const std::vector< DATA > &dataList)
void produce(edm::Event &e, const edm::EventSetup &es) override
std::string measurementTrackerLabel
std::vector< TrajectorySeed > TrajectorySeedCollection
std::unique_ptr< SeedFinderSelector > seedFinderSelector
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
static TrackingLayer createFromString(std::string layerSpecification)
bool hitIsMasked(const FastTrackerRecHit *hit, const std::vector< bool > &hitMasks)
std::vector< FastTrackerRecHitRef > FastTrackerRecHitCombination
std::vector< std::vector< TrackingLayer > > seedingLayers
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
edm::EDGetTokenT< FastTrackerRecHitCombinationCollection > recHitCombinationsToken
bool isUninitialized() const
SeedingTree< TrackingLayer > _seedingTree
T const * product() const
std::unique_ptr< SeedCreator > seedCreator
T get(const Candidate &c)