197 std::cout <<
"<BoostedTauSeedsProducer::produce (moduleLabel = " <<
moduleLabel_ <<
")>:" << std::endl;
213 auto selectedSubjets = std::make_unique<JetTypeCollection>();
216 auto selectedSubjetPFCandidateAssociationForIsolation =
217 std::make_unique<JetToPFCandidateAssociation>(&evt.
productGetter());
221 JetToConstitMap constitmap(subjets->
size());
224 const auto& thesubjets = *subjets;
225 for (
unsigned i = 0;
i < thesubjets.size(); ++
i) {
226 for (
unsigned j = 0;
j < thesubjets[
i].numberOfDaughters(); ++
j) {
227 constitmap[
i].emplace(thesubjets[
i].daughterPtr(
j).
key());
234 assert(subjet1 && subjet2);
236 std::cout <<
"processing jet #" <<
idx <<
":" << std::endl;
237 std::cout <<
" subjet1: Pt = " << subjet1->
pt() <<
", eta = " << subjet1->
eta() <<
", phi = " << subjet1->
phi()
238 <<
", mass = " << subjet1->
mass() <<
" (#constituents = " << subjet1->
nConstituents()
239 <<
", area = " << subjet1->
jetArea() <<
")" << std::endl;
240 std::cout <<
" subjet2: Pt = " << subjet2->
pt() <<
", eta = " << subjet2->
eta() <<
", phi = " << subjet2->
phi()
241 <<
", mass = " << subjet2->
mass() <<
" (#constituents = " << subjet2->
nConstituents()
242 <<
", area = " << subjet2->
jetArea() <<
")" << std::endl;
250 getJetConstituents(*subjet1, subjetConstituents1);
252 getJetConstituents(*subjet2, subjetConstituents2);
254 printJetConstituents(
"subjetConstituents1", subjetConstituents1);
255 printJetConstituents(
"subjetConstituents2", subjetConstituents2);
258 selectedSubjets->push_back(convertToPFJet<JetType, CandType>(*subjet1, subjetConstituents1));
260 selectedSubjets->push_back(convertToPFJet<JetType, CandType>(*subjet2, subjetConstituents2));
264 std::vector<edm::Ref<std::vector<CandType>>> pfCandidatesNotInSubjet1 =
265 getPFCandidates_exclJetConstituents<CandType>(*subjet1,
pfCandidates, constitmap[2 *
idx + 1],
false);
266 std::vector<edm::Ref<std::vector<CandType>>> pfCandidatesNotInSubjet2 =
267 getPFCandidates_exclJetConstituents<CandType>(*subjet2,
pfCandidates, constitmap[2 *
idx],
false);
269 std::cout <<
"#pfCandidatesNotInSubjet1 = " << pfCandidatesNotInSubjet1.size() << std::endl;
270 std::cout <<
"#pfCandidatesNotInSubjet2 = " << pfCandidatesNotInSubjet2.size() << std::endl;
275 for (
auto const& pfCandidate : pfCandidatesNotInSubjet1) {
276 selectedSubjetPFCandidateAssociationForIsolation->insert(subjetRef1, pfCandidate);
278 for (
auto const& pfCandidate : pfCandidatesNotInSubjet2) {
279 selectedSubjetPFCandidateAssociationForIsolation->insert(subjetRef2, pfCandidate);
284 evt.
put(
std::move(selectedSubjetPFCandidateAssociationForIsolation),
"pfCandAssocMapForIsolation");
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
double pt() const final
transverse momentum
Base class for all types of Jets.
std::vector< Constituent > Constituents
bool getByToken(EDGetToken token, Handle< PROD > &result) const
virtual float jetArea() const
get jet area
EDProductGetter const & productGetter() const
virtual int nConstituents() const
of constituents
const_reference at(size_type pos) const
RefProd< PROD > getRefBeforePut()
edm::EDGetTokenT< JetView > srcSubjets_
double mass() const final
mass
double phi() const final
momentum azimuthal angle
edm::EDGetTokenT< CandTypeCollection > srcPFCandidates_
std::vector< JetType > JetTypeCollection
double eta() const final
momentum pseudorapidity