7 src_(iConfig.getParameter<
edm::InputTag>(
"src")),
9 Njets_(iConfig.getParameter<
std::vector<unsigned> >(
"Njets")),
10 measureDefinition_(iConfig.getParameter<unsigned >(
"measureDefinition")),
11 beta_(iConfig.getParameter<double>(
"beta")),
12 R0_(iConfig.getParameter<double>(
"R0")),
13 Rcutoff_(iConfig.getParameter<double>(
"Rcutoff")),
14 axesDefinition_(iConfig.getParameter< unsigned >(
"axesDefinition")),
15 nPass_(iConfig.getParameter<
int>(
"nPass")),
16 akAxesR0_(iConfig.getParameter<double>(
"akAxesR0"))
18 for ( std::vector<unsigned>::const_iterator
n =
Njets_.begin();
n !=
Njets_.end(); ++
n )
20 std::ostringstream tauN_str;
21 tauN_str <<
"tau" << *
n;
23 produces<edm::ValueMap<float> >(tauN_str.str().c_str());
28 fastjet::contrib::NormalizedMeasure normalizedMeasure (
beta_,
R0_);
29 fastjet::contrib::UnnormalizedMeasure unnormalizedMeasure (
beta_);
30 fastjet::contrib::OriginalGeometricMeasure geometricMeasure (
beta_);
31 fastjet::contrib::NormalizedCutoffMeasure normalizedCutoffMeasure (
beta_,
R0_,
Rcutoff_);
32 fastjet::contrib::UnnormalizedCutoffMeasure unnormalizedCutoffMeasure(
beta_,
Rcutoff_);
35 fastjet::contrib::MeasureDefinition
const * measureDef = 0;
46 fastjet::contrib::KT_Axes kt_axes;
47 fastjet::contrib::CA_Axes ca_axes;
48 fastjet::contrib::AntiKT_Axes antikt_axes (
akAxesR0_);
49 fastjet::contrib::WTA_KT_Axes wta_kt_axes;
50 fastjet::contrib::WTA_CA_Axes wta_ca_axes;
51 fastjet::contrib::OnePass_KT_Axes onepass_kt_axes;
52 fastjet::contrib::OnePass_CA_Axes onepass_ca_axes;
53 fastjet::contrib::OnePass_AntiKT_Axes onepass_antikt_axes (
akAxesR0_);
54 fastjet::contrib::OnePass_WTA_KT_Axes onepass_wta_kt_axes;
55 fastjet::contrib::OnePass_WTA_CA_Axes onepass_wta_ca_axes;
56 fastjet::contrib::MultiPass_Axes multipass_axes (
nPass_);
58 fastjet::contrib::AxesDefinition
const * axesDef = 0;
60 case KT_Axes :
default : axesDef = &kt_axes;
break;
61 case CA_Axes : axesDef = &ca_axes;
break;
82 for ( std::vector<unsigned>::const_iterator
n =
Njets_.begin();
n !=
Njets_.end(); ++
n )
84 std::ostringstream tauN_str;
85 tauN_str <<
"tau" << *
n;
88 std::vector<float> tauN;
89 tauN.reserve(jets->size());
100 auto outT = std::make_unique<edm::ValueMap<float>>();
102 fillerT.insert(jets, tauN.begin(), tauN.end());
111 std::vector<fastjet::PseudoJet> FJparticles;
112 for (
unsigned k = 0;
k <
object->numberOfDaughters(); ++
k)
116 FJparticles.push_back( fastjet::PseudoJet( dp->px(), dp->py(), dp->pz(), dp->energy() ) );
118 edm::LogWarning(
"MissingJetConstituent") <<
"Jet constituent required for N-subjettiness computation is missing!";
121 return routine_->getTau(num, FJparticles);
std::auto_ptr< fastjet::contrib::Njettiness > routine_
unsigned measureDefinition_
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
std::vector< unsigned > Njets_
bool isNonnull() const
Checks for non-null.
float getTau(unsigned num, const edm::Ptr< reco::Jet > &object) const
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup)
NjettinessAdder(const edm::ParameterSet &iConfig)
edm::EDGetTokenT< edm::View< reco::Jet > > src_token_