25 inputComputerNames( params.getParameter<
std::vector<
std::
string> >(
"jetTagComputers") ),
31 weightFile(params.existsAs<
edm::FileInPath>(
"weightFile") ? params.getParameter<
edm::FileInPath>(
"weightFile") :
edm::FileInPath()),
36 uses(0,
"ipTagInfos");
37 uses(1,
"svAVRTagInfos");
38 uses(2,
"svIVFTagInfos");
39 uses(3,
"smTagInfos");
40 uses(4,
"seTagInfos");
69 record.
get(
name, computerHandle);
81 std::vector<const BaseTagInfo*> jpTagInfos({ &info.
getBase(0) });
84 std::vector<const BaseTagInfo*> avrTagInfos({ &info.
getBase(0), &info.
getBase(1) });
87 std::vector<const BaseTagInfo*> ivfTagInfos({ &info.
getBase(0), &info.
getBase(2) });
90 std::vector<const BaseTagInfo*> smTagInfos({ &info.
getBase(3) });
93 std::vector<const BaseTagInfo*> seTagInfos({ &info.
getBase(4) });
95 std::map<std::string,float>
inputs;
103 if (inputs[
"Jet_JP"] <= 0) {
104 inputs[
"Jet_JP"] = 0;
106 if (inputs[
"Jet_JBP"] <= 0) {
107 inputs[
"Jet_JBP"] = 0;
109 if (inputs[
"Jet_CSV"] <= 0) {
110 inputs[
"Jet_CSV"] = 0;
112 if (inputs[
"Jet_CSVIVF"] <= 0) {
113 inputs[
"Jet_CSVIVF"] = 0;
115 if (inputs[
"Jet_SoftMu"] <= 0) {
116 inputs[
"Jet_SoftMu"] = 0;
118 if (inputs[
"Jet_SoftEl"] <= 0) {
119 inputs[
"Jet_SoftEl"] = 0;
122 if (inputs[
"Jet_CSV"] >= 1) {
123 inputs[
"Jet_CSV"] = 1;
125 if (inputs[
"Jet_CSVIVF"] >= 1) {
126 inputs[
"Jet_CSVIVF"] = 1;
128 if (inputs[
"Jet_SoftMu"] >= 1) {
129 inputs[
"Jet_SoftMu"] = 1;
131 if (inputs[
"Jet_SoftEl"] >= 1) {
132 inputs[
"Jet_SoftEl"] = 1;
136 value =
mvaID->evaluate(inputs);
float discriminator(const TagInfoHelper &info) const override
const std::vector< std::string > variables
void initialize(const JetTagComputerRecord &record) override
CombinedMVAV2JetTagComputer(const edm::ParameterSet ¶meters)
std::unique_ptr< TMVAEvaluator > mvaID
PRODUCT const & get(ESGetToken< PRODUCT, T > const &iToken) const
~CombinedMVAV2JetTagComputer() override
const std::vector< std::string > spectators
std::vector< const JetTagComputer * > computers
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
const DepRecordT getRecord() const
void uses(unsigned int id, const std::string &label)
const reco::BaseTagInfo & getBase(unsigned int index) const
const std::string mvaName
const std::vector< std::string > inputComputerNames
const std::string gbrForestLabel
std::string fullPath() const
T const * product() const
const edm::FileInPath weightFile