diff --git a/InnerDetector/InDetRecTools/InDetVKalVxInJetTool/src/BTagVrtSec.cxx b/InnerDetector/InDetRecTools/InDetVKalVxInJetTool/src/BTagVrtSec.cxx index c490bb55c0025d22e0a143655ce331050e092a90..785d1fae4fdb11cbd4d61d61dde8e5af1f593b91 100755 --- a/InnerDetector/InDetRecTools/InDetVKalVxInJetTool/src/BTagVrtSec.cxx +++ b/InnerDetector/InDetRecTools/InDetVKalVxInJetTool/src/BTagVrtSec.cxx @@ -505,7 +505,7 @@ namespace InDet{ errorMatrix, Chi2PerTrk, TrkAtVrt, Chi2, *state, true); if(sc.isFailure()) continue; - if(projSV_PV(tmpVertex,primVrt,jetDir)<0.) continue; // Drop negative direction + if((projSV_PV(tmpVertex,primVrt,jetDir)<0. &&(!m_getNegativeTag)) || (projSV_PV(tmpVertex,primVrt,jetDir)>0. &&(m_getNegativeTag))) continue; // Drop negative direction if(m_useTrackClassificator) Chi2 += trkRank[it]; // Remove preferably non-HF-tracks @@ -713,7 +713,7 @@ namespace InDet{ tmpVrt.fitVertex.y()-primVrt.y(), tmpVrt.fitVertex.z()-primVrt.z()); tmpVrt.dRSVPV = jetDir.DeltaR(TLorentzVector(SVmPV, 1.)); //DeltaR SV-PV vs jet - if(tmpVrt.dRSVPV > m_coneForTag ) continue; // SV is outside of the jet cone + if( tmpVrt.dRSVPV > m_coneForTag && (!m_getNegativeTag) ) continue; // SV is outside of the jet cone double jetVrtDir = SVmPV.Dot(jetDir.Vect()); double vPos = SVmPV.Dot(tmpVrt.momentum.Vect())/tmpVrt.momentum.Rho(); diff --git a/PhysicsAnalysis/JetTagging/JetTagTools/python/SV1TagConfig.py b/PhysicsAnalysis/JetTagging/JetTagTools/python/SV1TagConfig.py index 09180d52180a0b16a872a855c2f65c19aed96c9e..2b5a78682430f85b7705be79c7df936565fc3f30 100644 --- a/PhysicsAnalysis/JetTagging/JetTagTools/python/SV1TagConfig.py +++ b/PhysicsAnalysis/JetTagging/JetTagTools/python/SV1TagConfig.py @@ -44,6 +44,8 @@ def SV1TagCfg( flags, name = 'SV1Tag', scheme = '', useBTagFlagsDefaults = True, 'UseCHypo' : True, 'LikelihoodTool' : likelihood } + if 'Flip' in name: + defaults['SecVxFinderName'] = 'SV1Flip' for option in defaults: options.setdefault(option, defaults[option]) acc.setPrivateTools(CompFactory.Analysis.SVTag(**options))