Static Public Member Functions | |
static void | fillDescriptions (edm::ConfigurationDescriptions &descriptions) |
static void | globalEndJob (const deep_tau::DeepTauCache *cache_) |
static std::unique_ptr< deep_tau::DeepTauCache > | initializeGlobalCache (const edm::ParameterSet &cfg) |
Static Public Member Functions inherited from DeepTauIdBase< DeepTauIdWrapper > | |
static void | fillDescriptionsHelper (edm::ParameterSetDescription &desc) |
static const IDOutputCollection & | GetIDOutputs () |
Private Member Functions | |
void | checkInputs (const tensorflow::Tensor &inputs, const std::string &block_name, int n_inputs, const CellGrid *grid=nullptr) const |
template<typename CandidateCastType , typename TauCastType > | |
void | createConvFeatures (const TauCastType &tau, const size_t tau_index, const edm::RefToBase< reco::BaseTau > tau_ref, const reco::Vertex &pv, double rho, const std::vector< pat::Electron > *electrons, const std::vector< pat::Muon > *muons, const edm::View< reco::Candidate > &pfCands, const CellGrid &grid, TauFunc tau_funcs, bool is_inner) |
tensorflow::Tensor | getPartialPredictions (bool is_inner) |
tensorflow::Tensor | getPredictions (edm::Event &event, edm::Handle< TauCollection > taus) |
template<typename CandidateCastType , typename TauCastType > | |
void | getPredictionsV2 (TauCollection::const_reference &tau, const size_t tau_index, const edm::RefToBase< reco::BaseTau > tau_ref, const std::vector< pat::Electron > *electrons, const std::vector< pat::Muon > *muons, const edm::View< reco::Candidate > &pfCands, const reco::Vertex &pv, double rho, const edm::EventNumber_t &eventnr, std::vector< tensorflow::Tensor > &pred_vector, TauFunc tau_funcs) |
void | saveInputs (const tensorflow::Tensor &inputs, const std::string &block_name, int n_inputs, const CellGrid *grid=nullptr) |
void | setCellConvFeatures (tensorflow::Tensor &convTensor, const tensorflow::Tensor &features, unsigned batch_idx, int eta_index, int phi_index) |
Private Attributes | |
const deep_tau::DeepTauCache * | cache_ |
std::array< std::unique_ptr< tensorflow::Tensor >, 2 > | convTensor_ |
std::array< std::unique_ptr< tensorflow::Tensor >, 2 > | eGammaTensor_ |
std::array< std::unique_ptr< tensorflow::Tensor >, 2 > | hadronsTensor_ |
std::array< std::unique_ptr< tensorflow::Tensor >, 2 > | muonTensor_ |
std::unique_ptr< tensorflow::Tensor > | tauBlockTensor_ |
std::array< std::unique_ptr< tensorflow::Tensor >, 2 > | zeroOutputTensor_ |
Additional Inherited Members | |
Public Types inherited from DeepTauIdBase< DeepTauIdWrapper > | |
using | BasicDiscriminator = deep_tau::BasicDiscriminator |
using | CandidateCollection = edm::View< reco::Candidate > |
using | Cutter = tau::TauWPThreshold |
using | CutterPtr = std::unique_ptr< Cutter > |
using | ElectronCollection = pat::ElectronCollection |
using | IDOutputCollection = std::map< std::string, IDOutput > |
using | LorentzVectorXYZ = ROOT::Math::LorentzVector< ROOT::Math::PxPyPzE4D< double > > |
using | MuonCollection = pat::MuonCollection |
using | TauCollection = edm::View< reco::BaseTau > |
using | TauDiscriminator = reco::TauDiscriminatorContainer |
using | TauRef = edm::Ref< TauCollection > |
using | TauRefProd = edm::RefProd< TauCollection > |
using | WPList = std::vector< CutterPtr > |
Public Types inherited from edm::stream::EDProducer< edm::GlobalCache< deep_tau::DeepTauCache > > | |
using | CacheTypes = CacheContexts< T... > |
using | GlobalCache = typename CacheTypes::GlobalCache |
using | HasAbility = AbilityChecker< T... > |
using | InputProcessBlockCache = typename CacheTypes::InputProcessBlockCache |
using | LuminosityBlockCache = typename CacheTypes::LuminosityBlockCache |
using | LuminosityBlockContext = LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCache > |
using | LuminosityBlockSummaryCache = typename CacheTypes::LuminosityBlockSummaryCache |
using | RunCache = typename CacheTypes::RunCache |
using | RunContext = RunContextT< RunCache, GlobalCache > |
using | RunSummaryCache = typename CacheTypes::RunSummaryCache |
Public Attributes inherited from DeepTauIdBase< DeepTauIdWrapper > | |
uint8_t | andPrediscriminants_ |
std::vector< TauDiscInfo< pat::PATTauDiscriminator > > | patPrediscriminants_ |
std::vector< TauDiscInfo< reco::PFTauDiscriminator > > | recoPrediscriminants_ |
Static Public Attributes inherited from DeepTauIdBase< DeepTauIdWrapper > | |
static constexpr float | default_value |
Protected Member Functions inherited from DeepTauIdBase< DeepTauIdWrapper > | |
void | createEgammaBlockInputs (unsigned idx, const TauCastType &tau, const size_t tau_index, const edm::RefToBase< reco::BaseTau > tau_ref, const reco::Vertex &pv, double rho, const std::vector< pat::Electron > *electrons, const edm::View< reco::Candidate > &pfCands, const Cell &cell_map, TauFunc tau_funcs, bool is_inner, EgammaBlockType &egammaBlockInputs) |
void | createHadronsBlockInputs (unsigned idx, const TauCastType &tau, const size_t tau_index, const edm::RefToBase< reco::BaseTau > tau_ref, const reco::Vertex &pv, double rho, const edm::View< reco::Candidate > &pfCands, const Cell &cell_map, TauFunc tau_funcs, bool is_inner, HadronBlockType &hadronBlockInputs) |
void | createMuonBlockInputs (unsigned idx, const TauCastType &tau, const size_t tau_index, const edm::RefToBase< reco::BaseTau > tau_ref, const reco::Vertex &pv, double rho, const std::vector< pat::Muon > *muons, const edm::View< reco::Candidate > &pfCands, const Cell &cell_map, TauFunc tau_funcs, bool is_inner, MuonBlockType &muonBlockInputs) |
void | createOutputs (edm::Event &event, const PredType &pred, edm::Handle< TauCollection > taus) |
void | createTauBlockInputs (const TauCastType &tau, const size_t &tau_index, const edm::RefToBase< reco::BaseTau > tau_ref, const reco::Vertex &pv, double rho, TauFunc tau_funcs, TauBlockType &tauBlockInputs) |
void | fillGrids (const TauCastType &tau, const Collection &objects, CellGrid &inner_grid, CellGrid &outer_grid) |
void | loadPrediscriminants (edm::Event const &event, edm::Handle< TauCollection > const &taus) |
Static Protected Member Functions inherited from DeepTauIdBase< DeepTauIdWrapper > | |
static void | calculateElectronClusterVars (const pat::Electron *ele, float &elecEe, float &elecEgamma) |
static bool | calculateElectronClusterVarsV2 (const pat::Electron &ele, float &cc_ele_energy, float &cc_gamma_energy, int &cc_n_gamma) |
static bool | calculateGottfriedJacksonAngleDifference (const TauCastType &tau, const size_t tau_index, double &gj_diff, TauFunc tau_funcs) |
static float | calculateGottfriedJacksonAngleDifference (const TauCastType &tau, const size_t tau_index, TauFunc tau_funcs) |
static const pat::Electron * | findMatchedElectron (const TauCastType &tau, const std::vector< pat::Electron > *electrons, double deltaR) |
static double | getInnerSignalConeRadius (double pt) |
static float | getValue (T value) |
static float | getValueLinear (T value, float min_value, float max_value, bool positive) |
static float | getValueNorm (T value, float mean, float sigma, float n_sigmas_max=5) |
static bool | isAbove (double value, double min) |
static bool | isInEcalCrack (double eta) |
static void | processIsolationPFComponents (const TauCastType &tau, const CandidateCollection &candidates, LorentzVectorXYZ &p4, float &pt, float &d_eta, float &d_phi, float &m, float &n) |
static void | processSignalPFComponents (const TauCastType &tau, const CandidateCollection &candidates, LorentzVectorXYZ &p4_inner, LorentzVectorXYZ &p4_outer, float &pt_inner, float &dEta_inner, float &dPhi_inner, float &m_inner, float &pt_outer, float &dEta_outer, float &dPhi_outer, float &m_outer, float &n_inner, float &n_outer) |
Protected Attributes inherited from DeepTauIdBase< DeepTauIdWrapper > | |
std::map< BasicDiscriminator, size_t > | basicDiscrdR03IndexMap_ |
std::map< BasicDiscriminator, size_t > | basicDiscrIndexMap_ |
edm::EDGetTokenT< reco::TauDiscriminatorContainer > | basicTauDiscriminators_inputToken_ |
edm::EDGetTokenT< reco::TauDiscriminatorContainer > | basicTauDiscriminatorsdR03_inputToken_ |
const int | debug_level |
const bool | disable_CellIndex_workaround_ |
const bool | disable_dxy_pca_ |
const bool | disable_hcalFraction_workaround_ |
bool | discrIndicesMapped_ |
edm::EDGetTokenT< std::vector< pat::Electron > > | electrons_token_ |
int | file_counter_ |
IDOutputCollection | idoutputs_ |
std::string | input_layer_ |
bool | is_first_block_ |
const bool | is_online_ |
std::ofstream * | json_file_ |
edm::EDGetTokenT< std::vector< pat::Muon > > | muons_token_ |
std::string | output_layer_ |
edm::EDGetTokenT< CandidateCollection > | pfcandToken_ |
edm::EDGetTokenT< edm::AssociationVector< reco::PFTauRefProd, std::vector< reco::PFTauTransverseImpactParameterRef > > > | pfTauTransverseImpactParameters_token_ |
const std::vector< BasicDiscriminator > | requiredBasicDiscriminators_ |
const std::vector< BasicDiscriminator > | requiredBasicDiscriminatorsdR03_ |
edm::EDGetTokenT< double > | rho_token_ |
const bool | save_inputs_ |
const std::map< std::pair< deep_tau::Scaling::FeatureT, bool >, deep_tau::Scaling::ScalingParams > * | scalingParamsMap_ |
const std::map< BasicDiscriminator, std::string > | stringFromDiscriminator_ |
const unsigned | sub_version_ |
std::vector< int > | tauInputs_indices_ |
edm::EDGetTokenT< TauCollection > | tausToken_ |
const unsigned | version_ |
edm::EDGetTokenT< reco::VertexCollection > | vtxToken_ |
std::map< std::string, WPList > | workingPoints_ |
const unsigned | year_ |
Static Protected Attributes inherited from DeepTauIdBase< DeepTauIdWrapper > | |
static constexpr float | pi |
Definition at line 78 of file DeepTauId.cc.
|
inlineexplicit |
Definition at line 89 of file DeepTauId.cc.
References convTensor_, eGammaTensor_, getPartialPredictions(), hadronsTensor_, muonTensor_, dqmiodumpmetadata::n, setCellConvFeatures(), findQualityFiles::size, DeepTauIdBase< DeepTauIdWrapper >::sub_version_, tauBlockTensor_, DeepTauIdBase< DeepTauIdWrapper >::version_, and zeroOutputTensor_.
|
inlineprivate |
Definition at line 169 of file DeepTauId.cc.
References cms::cuda::assert(), gather_cfg::cout, DeepTauIdBase< DeepTauIdWrapper >::debug_level, PVValHelper::eta, Exception, alignBH_cfg::fixed, nano_mu_digi_cff::float, getRunAppsInfo::grid, input, PixelMapPlotter::inputs, edm::isNotFinite(), and phi.
Referenced by getPredictionsV2().
|
inlineprivate |
Definition at line 538 of file DeepTauId.cc.
References convTensor_, gather_cfg::cout, DeepTauIdBase< DeepTauIdWrapper >::debug_level, eGammaTensor_, pwdgSkimBPark_cfi::electrons, PVValHelper::eta, getPartialPredictions(), getRunAppsInfo::grid, hadronsTensor_, heavyIonCSV_trainingSettings::idx, createfilelist::int, DiMuonV_cfg::muons, muonTensor_, phi, MetAnalyzer::pv(), rho, setCellConvFeatures(), metsig::tau, and zeroOutputTensor_.
|
inlinestatic |
Definition at line 80 of file DeepTauId.cc.
References edm::ConfigurationDescriptions::add(), submitPVResolutionJobs::desc, and DeepTauIdBase< DeepTauIdWrapper >::fillDescriptionsHelper().
|
inlineprivate |
Definition at line 512 of file DeepTauId.cc.
References cache_, eGammaTensor_, deep_tau::DeepTauCache::getSession(), hadronsTensor_, muonTensor_, and tensorflow::run().
Referenced by createConvFeatures(), and DeepTauId().
|
inlineprivate |
Definition at line 286 of file DeepTauId.cc.
References DeepTauIdBase< DeepTauIdWrapper >::andPrediscriminants_, DeepTauIdBase< DeepTauIdWrapper >::basicDiscrdR03IndexMap_, DeepTauIdBase< DeepTauIdWrapper >::basicDiscrIndexMap_, HLT_2024v11_cff::basicTauDiscriminators, DeepTauIdBase< DeepTauIdWrapper >::basicTauDiscriminators_inputToken_, HLT_2024v11_cff::basicTauDiscriminatorsdR03, DeepTauIdBase< DeepTauIdWrapper >::basicTauDiscriminatorsdR03_inputToken_, DeepTauIdBase< DeepTauIdWrapper >::discrIndicesMapped_, DeepTauIdBase< DeepTauIdWrapper >::electrons_token_, Exception, f, DeepTauIdBase< DeepTauIdWrapper >::is_online_, dqmdumpme::k, DeepTauIdBase< DeepTauIdWrapper >::matchDiscriminatorIndices(), DeepTauIdBase< DeepTauIdWrapper >::muons_token_, deep_tau::NumberOfOutputs, DeepTauIdBase< DeepTauIdWrapper >::patPrediscriminants_, DeepTauIdBase< DeepTauIdWrapper >::pfcandToken_, HLT_2024v11_cff::pfTauTransverseImpactParameters, DeepTauIdBase< DeepTauIdWrapper >::pfTauTransverseImpactParameters_token_, DeepTauIdBase< DeepTauIdWrapper >::recoPrediscriminants_, DeepTauIdBase< DeepTauIdWrapper >::requiredBasicDiscriminators_, DeepTauIdBase< DeepTauIdWrapper >::requiredBasicDiscriminatorsdR03_, rho, DeepTauIdBase< DeepTauIdWrapper >::rho_token_, Tau3MuMonitor_cff::taus, DeepTauIdBase< DeepTauIdWrapper >::version_, AlignmentTracksFromVertexSelector_cfi::vertices, and DeepTauIdBase< DeepTauIdWrapper >::vtxToken_.
Referenced by produce().
|
inlineprivate |
Definition at line 410 of file DeepTauId.cc.
References cms::cuda::assert(), cache_, checkInputs(), convTensor_, gather_cfg::cout, DeepTauIdBase< DeepTauIdWrapper >::debug_level, DeepTauIdBase< DeepTauIdWrapper >::disable_CellIndex_workaround_, eGammaTensor_, pwdgSkimBPark_cfi::electrons, DeepTauIdBase< DeepTauIdWrapper >::file_counter_, DeepTauIdBase< DeepTauIdWrapper >::fillGrids(), deep_tau::DeepTauCache::getSession(), hadronsTensor_, heavyIonCSV_trainingSettings::idx, DeepTauIdBase< DeepTauIdWrapper >::is_first_block_, DeepTauIdBase< DeepTauIdWrapper >::json_file_, label, DiMuonV_cfg::muons, muonTensor_, deep_tau::NumberOfOutputs, rho, tensorflow::run(), DeepTauIdBase< DeepTauIdWrapper >::save_inputs_, saveInputs(), AlCaHLTBitMon_QueryRunRegistry::string, metsig::tau, tauBlockTensor_, and to_string().
|
inlinestatic |
Definition at line 166 of file DeepTauId.cc.
|
inlinestatic |
Definition at line 144 of file DeepTauId.cc.
References looper::cfg, mps_splice::entry, edm::FileInPath::fullPath(), HLT_2024v11_cff::graph_file, HLT_2024v11_cff::mem_mapped, and AlCaHLTBitMon_QueryRunRegistry::string.
|
inlineoverride |
Definition at line 127 of file DeepTauId.cc.
References DeepTauIdBase< DeepTauIdWrapper >::createOutputs(), getPredictions(), DeepTauIdBase< DeepTauIdWrapper >::loadPrediscriminants(), deep_tau::NumberOfOutputs, Tau3MuMonitor_cff::taus, and DeepTauIdBase< DeepTauIdWrapper >::tausToken_.
|
inlineprivate |
Definition at line 225 of file DeepTauId.cc.
References cms::cuda::assert(), gather_cfg::cout, DeepTauIdBase< DeepTauIdWrapper >::debug_level, PVValHelper::eta, nano_mu_digi_cff::float, getRunAppsInfo::grid, input, PixelMapPlotter::inputs, DeepTauIdBase< DeepTauIdWrapper >::is_first_block_, and phi.
Referenced by getPredictionsV2().
|
inlineprivate |
Definition at line 639 of file DeepTauId.cc.
References lowptgsfeleseed::features(), nano_mu_digi_cff::float, and dqmiodumpmetadata::n.
Referenced by createConvFeatures(), and DeepTauId().
|
private |
Definition at line 650 of file DeepTauId.cc.
Referenced by getPartialPredictions(), and getPredictionsV2().
|
private |
Definition at line 653 of file DeepTauId.cc.
Referenced by createConvFeatures(), DeepTauId(), and getPredictionsV2().
|
private |
Definition at line 653 of file DeepTauId.cc.
Referenced by createConvFeatures(), DeepTauId(), getPartialPredictions(), and getPredictionsV2().
|
private |
Definition at line 653 of file DeepTauId.cc.
Referenced by createConvFeatures(), DeepTauId(), getPartialPredictions(), and getPredictionsV2().
|
private |
Definition at line 653 of file DeepTauId.cc.
Referenced by createConvFeatures(), DeepTauId(), getPartialPredictions(), and getPredictionsV2().
|
private |
Definition at line 652 of file DeepTauId.cc.
Referenced by DeepTauId(), and getPredictionsV2().
|
private |
Definition at line 653 of file DeepTauId.cc.
Referenced by createConvFeatures(), and DeepTauId().