Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
80 changes: 80 additions & 0 deletions DataFormats/BTauReco/interface/HLTParticleTransformerAK4Features.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
#ifndef DataFormats_BTauReco_HLTParticleTransformerAK4Features_h
#define DataFormats_BTauReco_HLTParticleTransformerAK4Features_h

#include <vector>

class HLTGlobalFeatures {
public:
float jet_pt;
float jet_eta;
float jet_phi;
float jet_energy;
};

class HLTCpfCandidateFeatures {
public:
float jet_pfcand_deta;
float jet_pfcand_dphi;
float jet_pfcand_pt_log;
float jet_pfcand_energy_log;
float jet_pfcand_charge;
float jet_pfcand_frompv;
float jet_pfcand_nlostinnerhits;
float jet_pfcand_track_chi2;
float jet_pfcand_track_qual;
float jet_pfcand_dz;
float jet_pfcand_dzsig;
float jet_pfcand_dxy;
float jet_pfcand_dxysig;
float jet_pfcand_etarel;
float jet_pfcand_pperp_ratio;
float jet_pfcand_ppara_ratio;
float jet_pfcand_trackjet_d3d;
float jet_pfcand_trackjet_d3dsig;
float jet_pfcand_trackjet_dist;
float jet_pfcand_trackjet_decayL;
float jet_pfcand_npixhits;
float jet_pfcand_nstriphits;
float jet_pfcand_highpurity;
float jet_pfcand_id;

float jet_pfcand_pt;
float jet_pfcand_eta;
float jet_pfcand_phi;
float jet_pfcand_energy;
};

class HLTVtxFeatures {
public:
float jet_sv_deta;
float jet_sv_dphi;
float jet_sv_pt_log;
float jet_sv_mass;
float jet_sv_ntrack;
float jet_sv_chi2;
float jet_sv_dxy;
float jet_sv_dxysig;
float jet_sv_d3d;
float jet_sv_d3dsig;
float jet_sv_costhetasvpv;
float jet_sv_enratio;

float jet_sv_pt;
float jet_sv_eta;
float jet_sv_phi;
float jet_sv_energy;
};

namespace btagbtvdeep {

class HLTParticleTransformerAK4Features {
public:
bool is_filled = true;
HLTGlobalFeatures global_features;
std::vector<HLTCpfCandidateFeatures> cpf_candidates;
std::vector<HLTVtxFeatures> vtx_features;
};

} // namespace btagbtvdeep

#endif
12 changes: 12 additions & 0 deletions DataFormats/BTauReco/interface/HLTParticleTransformerAK4TagInfo.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#ifndef DataFormats_BTauReco_HLTParticleTransformerAK4TagInfo_h
#define DataFormats_BTauReco_HLTParticleTransformerAK4TagInfo_h

#include "DataFormats/BTauReco/interface/HLTParticleTransformerAK4Features.h"
#include "DataFormats/BTauReco/interface/FeaturesTagInfo.h"

namespace reco {
typedef FeaturesTagInfo<btagbtvdeep::HLTParticleTransformerAK4Features> HLTParticleTransformerAK4TagInfo;
DECLARE_EDM_REFS(HLTParticleTransformerAK4TagInfo)
} // namespace reco

#endif // DataFormats_BTauReco_HLTParticleTransformerAK4TagInfo_h
2 changes: 2 additions & 0 deletions DataFormats/BTauReco/src/classes.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@
#include "DataFormats/BTauReco/interface/DeepDoubleXTagInfo.h"
#include "DataFormats/BTauReco/interface/ParticleTransformerAK4Features.h"
#include "DataFormats/BTauReco/interface/ParticleTransformerAK4TagInfo.h"
#include "DataFormats/BTauReco/interface/HLTParticleTransformerAK4Features.h"
#include "DataFormats/BTauReco/interface/HLTParticleTransformerAK4TagInfo.h"
#include "DataFormats/BTauReco/interface/UnifiedParticleTransformerAK4Features.h"
#include "DataFormats/BTauReco/interface/UnifiedParticleTransformerAK4TagInfo.h"
#include "DataFormats/BTauReco/interface/DeepBoostedJetTagInfo.h"
Expand Down
8 changes: 8 additions & 0 deletions DataFormats/BTauReco/src/classes_def.xml
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,14 @@
<class name="reco::ParticleTransformerAK4TagInfoRefVector"/>
<class name="edm::Wrapper<reco::ParticleTransformerAK4TagInfoCollection>"/>

<class name="reco::HLTParticleTransformerAK4TagInfo"/>
<class name="reco::HLTParticleTransformerAK4TagInfoCollection"/>
<class name="reco::HLTParticleTransformerAK4TagInfoRef"/>
<class name="reco::HLTParticleTransformerAK4TagInfoFwdRef"/>
<class name="reco::HLTParticleTransformerAK4TagInfoRefProd"/>
<class name="reco::HLTParticleTransformerAK4TagInfoRefVector"/>
<class name="edm::Wrapper<reco::HLTParticleTransformerAK4TagInfoCollection>"/>

<class name="reco::UnifiedParticleTransformerAK4TagInfo"/>
<class name="reco::UnifiedParticleTransformerAK4TagInfoCollection"/>
<class name="reco::UnifiedParticleTransformerAK4TagInfoRef"/>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import FWCore.ParameterSet.Config as cms

hltDoublePFJets30ParTTauhTagMediumWPL2DoubleTau = cms.EDFilter( "TauTagFilter",
saveTags = cms.bool( True ),
nExpected = cms.int32( 2 ),
taus = cms.InputTag( "hltAK4PFPuppiJets" ),
tauTags = cms.InputTag( 'hltParticleTransformerDiscriminatorsJetTags','TauvsAll' ),
tauPtCorr = cms.InputTag( '','' ),
seeds = cms.InputTag( "hltL1P2GTTau" ),
seedTypes = cms.vint32( +84 ),
selection = cms.string( "0.11645" ),
minPt = cms.double( 30.0 ),
maxEta = cms.double( 2.1 ),
usePtCorr = cms.bool( False ),
matchWithSeeds = cms.bool( False ),
matchingdR = cms.double( 0.5 )
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import FWCore.ParameterSet.Config as cms

hltPFJetForBtagSelector = cms.EDFilter( "HLT1PFJet",
saveTags = cms.bool( True ),
inputTag = cms.InputTag( "hltAK4PFPuppiJets" ),
triggerType = cms.int32( 86 ),
MinE = cms.double( -1.0 ),
MinPt = cms.double( 30.0 ),
MinMass = cms.double( -1.0 ),
MaxMass = cms.double( -1.0 ),
MinEta = cms.double( -1.0 ),
MaxEta = cms.double( 2.1 ),
MinN = cms.int32( 1 )
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import FWCore.ParameterSet.Config as cms

hltPFJetForBtag = cms.EDProducer( "HLTPFJetCollectionProducer",
HLTObject = cms.InputTag( "hltPFJetForBtagSelector" ),
TriggerTypes = cms.vint32( 86 )
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import FWCore.ParameterSet.Config as cms

hltParticleTransformerAK4TagInfos = cms.EDProducer("HLTParticleTransformerAK4TagInfoProducer",
candidates = cms.InputTag("hltParticleFlowTmp"),
jet_radius = cms.double(0.4),
jets = cms.InputTag("hltAK4PFPuppiJets"),
mightGet = cms.optional.untracked.vstring,
min_candidate_pt = cms.double(0.1),
min_jet_pt = cms.double(5),
max_jet_eta = cms.double(2.1),
secondary_vertices = cms.InputTag("hltDeepInclusiveMergedVerticesPF"),
vertex_associator = cms.InputTag("hltPrimaryVertexAssociation","original"),
vertices = cms.InputTag("hltOfflinePrimaryVertices")
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import FWCore.ParameterSet.Config as cms

hltParticleTransformerDiscriminatorsJetTags = cms.EDProducer("BTagProbabilityToDiscriminator",
discriminators = cms.VPSet(
cms.PSet(name = cms.string("TauvsAll"),
numerator = cms.VInputTag('hltParticleTransformerONNXJetTags:probtaup',
'hltParticleTransformerONNXJetTags:probtaum'),
denominator = cms.VInputTag(
'hltParticleTransformerONNXJetTags:probb',
'hltParticleTransformerONNXJetTags:probg',
'hltParticleTransformerONNXJetTags:probtaup',
'hltParticleTransformerONNXJetTags:probtaum',
'hltParticleTransformerONNXJetTags:probc',
'hltParticleTransformerONNXJetTags:probuds'
)
)
)
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import FWCore.ParameterSet.Config as cms

hltParticleTransformerONNXJetTags = cms.EDProducer( "HLTParticleTransformerAK4ONNXJetTagsProducer",
src = cms.InputTag( "hltParticleTransformerAK4TagInfos" ),
model_path = cms.FileInPath( "RecoBTag/Combined/data/HLT/hltParticleTransformerAK4/hltParTAK4_CMSSW15_082026.onnx" ),
flav_names = cms.vstring(
"probb",
"probc",
"probuds",
"probg",
"probtaup",
"probtaum",
),
input_names = cms.vstring(
"global",
"cpf",
"vtx",
),
output_names = cms.vstring("output"),
mightGet = cms.optional.untracked.vstring,
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import FWCore.ParameterSet.Config as cms

from ..sequences.HLTBeginSequence_cfi import *
from ..sequences.HLTEndSequence_cfi import *
from ..sequences.HLTAK4PFPuppiJetsReconstruction_cfi import *
from ..sequences.HLTJetFlavourTagParticleTransformerSequencePF_cfi import *
from ..modules.hltL1P2GTTau_cfi import *
from ..sequences.HLTTICLLocalRecoSequence_cfi import *
from ..sequences.HLTMuonsSequence_cfi import *
from ..sequences.HLTParticleFlowSequence_cfi import *
from ..sequences.HLTTrackingSequence_cfi import *
from ..sequences.HLTLocalrecoSequence_cfi import *
from ..sequences.HLTRawToDigiSequence_cfi import *
from ..modules.hltDoublePFJets30ParTTauhTagMediumWPL2DoubleTau_cfi import *

HLT_DoubleMediumPFPuppiParTTauh30_eta2p1 = cms.Path(
HLTBeginSequence +
hltL1P2GTTau +
HLTRawToDigiSequence +
HLTLocalrecoSequence +
HLTTICLLocalRecoSequence +
HLTTrackingSequence +
HLTMuonsSequence +
HLTParticleFlowSequence +
HLTAK4PFPuppiJetsReconstruction +
HLTJetFlavourTagParticleTransformerSequencePF +
hltDoublePFJets30ParTTauhTagMediumWPL2DoubleTau +
HLTEndSequence
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import FWCore.ParameterSet.Config as cms

from ..modules.hltDeepInclusiveMergedVerticesPF_cfi import *
from ..modules.hltDeepInclusiveSecondaryVerticesPF_cfi import *
from ..modules.hltDeepInclusiveVertexFinderPF_cfi import *
from ..modules.hltPrimaryVertexAssociation_cfi import *
from ..modules.hltDeepTrackVertexArbitratorPF_cfi import *
from ..modules.hltPFJetForBtagSelector_cfi import *
from ..modules.hltPFJetForBtag_cfi import *
from ..modules.hltParticleTransformerAK4TagInfos_cfi import *
from ..modules.hltParticleTransformerONNXJetTags_cfi import *
from ..modules.hltParticleTransformerDiscriminatorsJetTags_cfi import *

HLTJetFlavourTagParticleTransformerSequencePF = cms.Sequence(
hltPFJetForBtagSelector +
hltPFJetForBtag +
hltDeepInclusiveVertexFinderPF +
hltDeepInclusiveSecondaryVerticesPF +
hltDeepTrackVertexArbitratorPF +
hltDeepInclusiveMergedVerticesPF +
hltPrimaryVertexAssociation +
hltParticleTransformerAK4TagInfos +
hltParticleTransformerONNXJetTags +
hltParticleTransformerDiscriminatorsJetTags
)
5 changes: 2 additions & 3 deletions HLTrigger/Configuration/python/HLT_75e33_cff.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@
### Paths
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/DST_PFScouting_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_AK4PFPuppiJet520_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoubleMediumPFPuppiParTTauh30_eta2p1_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_Diphoton30_23_IsoCaloId_L1Seeded_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_Diphoton30_23_IsoCaloId_Unseeded_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoubleEle23_12_Iso_L1Seeded_cfi")
Expand Down Expand Up @@ -325,12 +326,10 @@

fragment.HLT_DoubleMediumChargedIsoPFTauHPS40_eta2p1,
fragment.HLT_DoubleMediumDeepTauPFTauHPS35_eta2p1,
fragment.HLT_DoubleMediumPFPuppiParTTauh30_eta2p1,
fragment.HLT_IsoMu20_eta2p1_LooseDeepTauPFTauHPS27_eta2p1_CrossL1,
fragment.HLT_Ele30_WPTight_L1Seeded_LooseDeepTauPFTauHPS30_eta2p1_CrossL1,
fragment.HLT_LooseDeepTauPFTauHPS150_L1NN_eta2p1,
### Removed temporarily until final decision on L1T tau Phase-2
#fragment.L1T_DoubleNNTau52,
#fragment.L1T_SingleNNTau150,

fragment.MC_JME,
fragment.MC_BTV,
Expand Down
6 changes: 2 additions & 4 deletions HLTrigger/Configuration/python/HLT_75e33_timing_cff.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoubleEle25_CaloIdL_PMS2_L1Seeded_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoubleMediumChargedIsoPFTauHPS40_eta2p1_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoubleMediumDeepTauPFTauHPS35_eta2p1_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoubleMediumPFPuppiParTTauh30_eta2p1_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_DoublePFPuppiJets128_DoublePFPuppiBTagDeepFlavour_2p4_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_Ele115_NonIso_L1Seeded_cfi")
fragment.load("HLTrigger/Configuration/HLT_75e33/paths/HLT_Ele26_WP70_L1Seeded_cfi")
Expand Down Expand Up @@ -290,10 +291,7 @@
fragment.HLT_DoubleMediumDeepTauPFTauHPS35_eta2p1,
fragment.HLT_IsoMu20_eta2p1_LooseDeepTauPFTauHPS27_eta2p1_CrossL1,
fragment.HLT_LooseDeepTauPFTauHPS150_L1NN_eta2p1,

### Removed temporarily until final decision on L1T tau Phase-2
#fragment.L1T_DoubleNNTau52,
#fragment.L1T_SingleNNTau150,
fragment.HLT_DoubleMediumPFPuppiParTTauh30_eta2p1,

fragment.HLTriggerFinalPath,
fragment.HLTAnalyzerEndpath,
Expand Down
1 change: 1 addition & 0 deletions HLTrigger/NGTScouting/python/hltTriggerObjects_cff.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"HLT_Diphoton30_23_IsoCaloId_L1Seeded",
"HLT_DoubleMediumChargedIsoPFTauHPS40_eta2p1",
"HLT_DoubleMediumDeepTauPFTauHPS35_eta2p1",
"HLT_DoubleMediumPFPuppiParTTauh30_eta2p1",
"HLT_IsoMu20_eta2p1_LooseDeepTauPFTauHPS27_eta2p1_CrossL1",
"HLT_Ele30_WPTight_L1Seeded_LooseDeepTauPFTauHPS30_eta2p1_CrossL1"
),
Expand Down
Loading