From a8093ee44966cf4ccc8f2a6be1222887d6b14a66 Mon Sep 17 00:00:00 2001 From: Atlas-Software Librarian <Atlas-Software.Librarian@cern.ch> Date: Fri, 8 Apr 2016 18:26:14 +0200 Subject: [PATCH] 'CMakeLists.txt' (IsolationAlgs-00-01-23) * Tagging IsolationAlgs-00-01-23. * src/IsolationBuilder.cxx: Another coverity warning. 2015-04-06 scott snyder <snyder@bnl.gov> * Tagging IsolationAlgs-00-01-22. * src/IsolationBuilder.cxx: Fix coverity warnings. 2015-03-27 scott snyder <snyder@bnl.gov> * Tagging IsolationAlgs-00-01-21. * PyCintex -> cppyy. 16-03-2015 Jean-Baptiste de Vivie * too much debug printout * tagging as IsolationAlgs-00-01-20 --- .../RecoAlgs/IsolationAlgs/CMakeLists.txt | 33 +++++++++++++++++++ .../IsolationAlgs/python/IsoGetter.py | 8 ++--- .../IsolationAlgs/python/IsoGetter.pyMod | 6 ++-- .../IsolationAlgs/src/IsolationBuilder.cxx | 9 +++-- 4 files changed, 46 insertions(+), 10 deletions(-) create mode 100644 Reconstruction/RecoAlgs/IsolationAlgs/CMakeLists.txt diff --git a/Reconstruction/RecoAlgs/IsolationAlgs/CMakeLists.txt b/Reconstruction/RecoAlgs/IsolationAlgs/CMakeLists.txt new file mode 100644 index 00000000000..dcaf1d2a4b2 --- /dev/null +++ b/Reconstruction/RecoAlgs/IsolationAlgs/CMakeLists.txt @@ -0,0 +1,33 @@ +################################################################################ +# Package: IsolationAlgs +################################################################################ + +# Declare the package name: +atlas_subdir( IsolationAlgs ) + +# Declare the package's dependencies: +atlas_depends_on_subdirs( PUBLIC + GaudiKernel + PRIVATE + Calorimeter/CaloEvent + Control/AthContainers + Control/AthenaBaseComps + Event/xAOD/xAODEgamma + Event/xAOD/xAODMuon + Event/xAOD/xAODPrimitives + Reconstruction/RecoTools/RecoToolInterfaces ) + +# External dependencies: +find_package( Boost COMPONENTS filesystem thread system ) + +# Component(s) in the package: +atlas_add_component( IsolationAlgs + src/*.cxx + src/components/*.cxx + INCLUDE_DIRS ${Boost_INCLUDE_DIRS} + LINK_LIBRARIES ${Boost_LIBRARIES} GaudiKernel CaloEvent AthContainers AthenaBaseComps xAODEgamma xAODMuon xAODPrimitives RecoToolInterfaces ) + +# Install files from the package: +atlas_install_python_modules( python/*.py ) +atlas_install_joboptions( share/*.py ) + diff --git a/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.py b/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.py index 31e17ca4f58..20845da18a1 100644 --- a/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.py +++ b/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.py @@ -168,10 +168,10 @@ tit.TrackSelectionTool.maxZ0SinTheta = 3 tit.TrackSelectionTool.minPt = 1000 tit.TrackSelectionTool.CutLevel = "Loose" -import ROOT, PyCintex +import ROOT, cppyy # Need to be sure base dict is loaded first. -PyCintex.loadDictionary('xAODCoreRflxDict') -PyCintex.loadDictionary('xAODPrimitivesDict') +cppyy.loadDictionary('xAODCoreRflxDict') +cppyy.loadDictionary('xAODPrimitivesDict') isoPar = ROOT.xAOD.Iso # In fact the default isolations are the same for eg and muons : prepare the list here @@ -236,7 +236,7 @@ class isoGetter ( Configured ) : print traceback.format_exc() return False - print self._isoBuilderHandle + #print self._isoBuilderHandle return True def isoBuilderHandle(self): diff --git a/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.pyMod b/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.pyMod index 5138f7467df..cc7d28de140 100644 --- a/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.pyMod +++ b/Reconstruction/RecoAlgs/IsolationAlgs/python/IsoGetter.pyMod @@ -160,10 +160,10 @@ tit.TrackSelectionTool.maxZ0SinTheta = 3 tit.TrackSelectionTool.minPt = 1000 tit.TrackSelectionTool.CutLevel = "TightPrimary" -import ROOT, PyCintex +import ROOT, cppyy # Need to be sure base dict is loaded first. -PyCintex.loadDictionary('xAODCoreRflxDict') -PyCintex.loadDictionary('xAODPrimitivesDict') +cppyy.loadDictionary('xAODCoreRflxDict') +cppyy.loadDictionary('xAODPrimitivesDict') isoPar = ROOT.xAOD.Iso # In fact the default isolations are the same for eg and muons : prepare the list here diff --git a/Reconstruction/RecoAlgs/IsolationAlgs/src/IsolationBuilder.cxx b/Reconstruction/RecoAlgs/IsolationAlgs/src/IsolationBuilder.cxx index 3964f9a56d2..16230240a46 100644 --- a/Reconstruction/RecoAlgs/IsolationAlgs/src/IsolationBuilder.cxx +++ b/Reconstruction/RecoAlgs/IsolationAlgs/src/IsolationBuilder.cxx @@ -38,7 +38,8 @@ IsolationBuilder::IsolationBuilder( const std::string& name, ISvcLocator* pSvcLocator ) : - ::AthAlgorithm( name, pSvcLocator ) + ::AthAlgorithm( name, pSvcLocator ), + m_cellColl (nullptr) { // // Property declaration @@ -77,7 +78,8 @@ StatusCode IsolationBuilder::initialize() for (unsigned int ii = 0; ii < nI; ii++) { std::vector<xAOD::Iso::IsolationType> isoTypes; std::vector<SG::AuxElement::Decorator<float>*> Deco; - xAOD::Iso::IsolationFlavour isoFlav; + xAOD::Iso::IsolationFlavour isoFlav = + xAOD::Iso::numIsolationFlavours; for (unsigned int jj = 0; jj < m_egisoInts[ii].size(); jj++) { int egIso = int(m_egisoInts[ii][jj]+0.5); xAOD::Iso::IsolationType isoType = static_cast<xAOD::Iso::IsolationType>(egIso); @@ -133,7 +135,8 @@ StatusCode IsolationBuilder::initialize() for (unsigned int ii = 0; ii < nI; ii++) { std::vector<xAOD::Iso::IsolationType> isoTypes; std::vector<SG::AuxElement::Decorator<float>*> Deco; - xAOD::Iso::IsolationFlavour isoFlav; + xAOD::Iso::IsolationFlavour isoFlav = + xAOD::Iso::numIsolationFlavours; for (unsigned int jj = 0; jj < m_muisoInts[ii].size(); jj++) { int muIso = int(m_muisoInts[ii][jj]+0.5); xAOD::Iso::IsolationType isoType = static_cast<xAOD::Iso::IsolationType>(muIso); -- GitLab