From 25b55181be2b0bd7df56ba6fa04c425ab46fc34e Mon Sep 17 00:00:00 2001 From: jean-roch Date: Tue, 2 Apr 2024 13:47:02 +0200 Subject: [PATCH 1/2] add ParticleNet C vs notB branch --- PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py | 1 + PhysicsTools/NanoAOD/python/nanoDQM_cfi.py | 1 + 2 files changed, 2 insertions(+) diff --git a/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py b/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py index 5c4673adbe732..adc5e37011c0c 100644 --- a/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py +++ b/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py @@ -108,6 +108,7 @@ btagRobustParTAK4CvB = Var("?(bDiscriminator('pfParticleTransformerAK4JetTags:probc')+bDiscriminator('pfParticleTransformerAK4JetTags:probb')+bDiscriminator('pfParticleTransformerAK4JetTags:probbb')+bDiscriminator('pfParticleTransformerAK4JetTags:problepb'))>0?bDiscriminator('pfParticleTransformerAK4JetTags:probc')/(bDiscriminator('pfParticleTransformerAK4JetTags:probc')+bDiscriminator('pfParticleTransformerAK4JetTags:probb')+bDiscriminator('pfParticleTransformerAK4JetTags:probbb')+bDiscriminator('pfParticleTransformerAK4JetTags:problepb')):-1",float,doc="RobustParTAK4 c vs b+bb+lepb discriminator",precision=10), btagRobustParTAK4QG = Var("?(bDiscriminator('pfParticleTransformerAK4JetTags:probg')+bDiscriminator('pfParticleTransformerAK4JetTags:probuds'))>0?bDiscriminator('pfParticleTransformerAK4JetTags:probg')/(bDiscriminator('pfParticleTransformerAK4JetTags:probg')+bDiscriminator('pfParticleTransformerAK4JetTags:probuds')):-1",float,doc="RobustParTAK4 g vs uds discriminator",precision=10), btagPNetB = Var("?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:BvsAll')>0?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:BvsAll'):-1",float,precision=10,doc="ParticleNet b vs. udscg"), + btagPNetCvNotB = Var("?(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probuds')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probmu')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probele')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probq')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg'))>0?(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probc'))/(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probuds')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probmu')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probele')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probq')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')):-1",float,precision=10,doc="ParticleNet C vs notB"), btagPNetCvL = Var("?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsL')>0?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsL'):-1",float,precision=10,doc="ParticleNet c vs. udsg"), btagPNetCvB = Var("?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsB')>0?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsB'):-1",float,precision=10,doc="ParticleNet c vs. b"), btagPNetQvG = Var("?abs(eta())<2.5?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:QvsG'):bDiscriminator('pfParticleNetFromMiniAODAK4PuppiForwardDiscriminatorsJetTags:QvsG')",float,precision=10,doc="ParticleNet q (udsbc) vs. g"), diff --git a/PhysicsTools/NanoAOD/python/nanoDQM_cfi.py b/PhysicsTools/NanoAOD/python/nanoDQM_cfi.py index c9a7dccc063b5..c7ea821680a3e 100644 --- a/PhysicsTools/NanoAOD/python/nanoDQM_cfi.py +++ b/PhysicsTools/NanoAOD/python/nanoDQM_cfi.py @@ -418,6 +418,7 @@ Plot1D('cRegCorr', 'cRegCorr', 20, 0.6, 2, 'pt correction for c-jet energy regression'), Plot1D('cRegRes', 'cRegRes', 20, 0.05, 0.4, 'res on pt corrected with c-jet regression'), Plot1D('btagPNetB', 'btagPNetB', 20, 0, 1, 'ParticleNet b tag discriminator'), + Plot1D('btagPNetCvNotB', 'btagPNetCvNotB', 20, 0, 1, 'ParticleNet C vs notB'), Plot1D('btagPNetCvL', 'btagPNetCvL', 20, 0, 1, 'ParticleNet c vs. light (udsg) discriminator'), Plot1D('btagPNetCvB', 'btagPNetCvB', 20, 0, 1, 'ParticleNet c vs. b discriminator'), Plot1D('btagPNetQvG', 'btagPNetQvG', 20, 0, 1, 'ParticleNet quark (udsbc) vs. gluon discriminator'), From 995e2e5e95358578dfdbc579ce80ebddadfa63c9 Mon Sep 17 00:00:00 2001 From: jean-roch Date: Wed, 3 Apr 2024 12:44:26 +0200 Subject: [PATCH 2/2] fix: btagPNetCvNotB score definition --- PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py b/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py index adc5e37011c0c..9ca15abe8b816 100644 --- a/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py +++ b/PhysicsTools/NanoAOD/python/jetsAK4_Puppi_cff.py @@ -108,7 +108,7 @@ btagRobustParTAK4CvB = Var("?(bDiscriminator('pfParticleTransformerAK4JetTags:probc')+bDiscriminator('pfParticleTransformerAK4JetTags:probb')+bDiscriminator('pfParticleTransformerAK4JetTags:probbb')+bDiscriminator('pfParticleTransformerAK4JetTags:problepb'))>0?bDiscriminator('pfParticleTransformerAK4JetTags:probc')/(bDiscriminator('pfParticleTransformerAK4JetTags:probc')+bDiscriminator('pfParticleTransformerAK4JetTags:probb')+bDiscriminator('pfParticleTransformerAK4JetTags:probbb')+bDiscriminator('pfParticleTransformerAK4JetTags:problepb')):-1",float,doc="RobustParTAK4 c vs b+bb+lepb discriminator",precision=10), btagRobustParTAK4QG = Var("?(bDiscriminator('pfParticleTransformerAK4JetTags:probg')+bDiscriminator('pfParticleTransformerAK4JetTags:probuds'))>0?bDiscriminator('pfParticleTransformerAK4JetTags:probg')/(bDiscriminator('pfParticleTransformerAK4JetTags:probg')+bDiscriminator('pfParticleTransformerAK4JetTags:probuds')):-1",float,doc="RobustParTAK4 g vs uds discriminator",precision=10), btagPNetB = Var("?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:BvsAll')>0?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:BvsAll'):-1",float,precision=10,doc="ParticleNet b vs. udscg"), - btagPNetCvNotB = Var("?(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probuds')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probmu')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probele')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probq')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg'))>0?(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probc'))/(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probuds')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probmu')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probele')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probq')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')):-1",float,precision=10,doc="ParticleNet C vs notB"), + btagPNetCvNotB = Var("?(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probc')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probuds')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probmu')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probele')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probq')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg'))>0?(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probc'))/(bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probc')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probuds')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probmu')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probele')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaup3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum1h2p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h0p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probtaum3h1p')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probq')+bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralJetTags:probg')):-1",float,precision=10,doc="ParticleNet C vs notB"), btagPNetCvL = Var("?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsL')>0?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsL'):-1",float,precision=10,doc="ParticleNet c vs. udsg"), btagPNetCvB = Var("?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsB')>0?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:CvsB'):-1",float,precision=10,doc="ParticleNet c vs. b"), btagPNetQvG = Var("?abs(eta())<2.5?bDiscriminator('pfParticleNetFromMiniAODAK4PuppiCentralDiscriminatorsJetTags:QvsG'):bDiscriminator('pfParticleNetFromMiniAODAK4PuppiForwardDiscriminatorsJetTags:QvsG')",float,precision=10,doc="ParticleNet q (udsbc) vs. g"),