9 :
TriggerObject(ecalCand), hasPixelMatch_(
false), superCluster_(ecalCand.superCluster()) {}
13 hasPixelMatch_ =
false;
14 for (
const auto&
seed : seeds_) {
15 if (!
seed->hitInfo().empty()) {
16 hasPixelMatch_ =
true;
23 return std::binary_search(vars_.begin(), vars_.end(), varName,
VarComparer());
28 auto varIt = std::equal_range(vars_.begin(), vars_.end(), varName,
VarComparer());
29 if (varIt.first != varIt.second)
30 return varIt.first->second;
31 else if (raiseExcept) {
33 ex <<
" error variable " << varName <<
" is not present, variables present are " << varNamesStr();
41 std::vector<std::string>
names;
42 for (
const auto&
var : vars_) {
43 names.push_back(
var.first);
61 std::sort(vars_.begin(), vars_.end(), [](
auto& lhs,
auto& rhs) {
return lhs.first < rhs.first; });
std::vector< std::string > varNames() const
void setVars(std::vector< std::pair< std::string, float >> vars)
std::string varNamesStr() const
constexpr char const * varNames[]
const std::string names[nVars_]
Single trigger physics object (e.g., an isolated muon)
float var(const std::string &varName, bool raiseExcept=true) const
list var
if using global norm cols_to_minmax = ['t_delta', 't_hmaxNearP','t_emaxNearP', 't_hAnnular', 't_eAnnular','t_pt','t_nVtx','t_ieta','t_eHcal10', 't_eHcal30','t_rhoh','t_eHcal'] df[cols_to_minmax] = df[cols_to_minmax].apply(lambda x: (x - x.min()) / (x.max() - x.min()) if (x.max() - x.min() > 0) else 1.0/200.0)
void setSeeds(reco::ElectronSeedRefVector seeds)
bool hasVar(const std::string &varName) const