Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Alexander Undrus
athena
Commits
e8522ac6
Commit
e8522ac6
authored
Sep 29, 2021
by
marco aparo
Browse files
Migrated Tag&Probe class to TrigInDetAnalysisUtils
parent
62611340
Changes
5
Hide whitespace changes
Inline
Side-by-side
Trigger/TrigAnalysis/TrigInDetAnalysisUser/Analysis/src/Makefile
View file @
e8522ac6
...
...
@@ -156,8 +156,7 @@ ROBJECTS = \
$(OBJDIR)
/ConfVtxAnalysis.o
\
$(OBJDIR)
/PurityAnalysis.o
\
$(OBJDIR)
/globals.o
\
$(OBJDIR)
/computils.o
\
$(OBJDIR)
/TagNProbe.o
$(OBJDIR)
/computils.o
LOBJECTS
=
\
$(OBJDIR)
/TIDAEvent.o
\
...
...
Trigger/TrigAnalysis/TrigInDetAnalysisUser/Analysis/src/rmain.cxx
View file @
e8522ac6
...
...
@@ -72,8 +72,8 @@
/// globals for communicating with *Analyses
#include "globals.h"
/// TagNProbe
routine
class
#include "TagNProbe.h"
/// TagNProbe class
#include "
TrigInDetAnalysisUtils/
TagNProbe.h"
// in ConfAnalysis
...
...
Trigger/TrigAnalysis/TrigInDetAnalysisUser/CMakeLists.txt
View file @
e8522ac6
...
...
@@ -57,7 +57,7 @@ atlas_add_executable( TIDAreader
LINK_LIBRARIES
${
ROOT_LIBRARIES
}
TrigInDetAnalysis Readcards
)
atlas_add_executable
(
TIDArdict
Analysis/src/rmain.cxx
Analysis/src/TagNProbe.h Analysis/src/TagNProbe.cxx
Analysis/src/rmain.cxx
INCLUDE_DIRS
${
ROOT_INCLUDE_DIRS
}
LINK_LIBRARIES
${
ROOT_LIBRARIES
}
TrigInDetAnalysis TrigInDetAnalysisUtils
TrigInDetAnalysisExampleLib Resplot Readcards TIDA TIDAcomputils
)
...
...
Trigger/TrigAnalysis/TrigInDetAnalysisU
ser/
Analysis
/src
/TagNProbe.h
→
Trigger/TrigAnalysis/TrigInDetAnalysisU
tils/TrigInDet
Analysis
Utils
/TagNProbe.h
View file @
e8522ac6
...
...
@@ -7,8 +7,9 @@
** Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
**/
#ifndef TIDA_TAGNPROBE_H
#define TIDA_TAGNPROBE_H
#ifndef TIDAUTILS_TAGNPROBE_H
#define TIDAUTILS_TAGNPROBE_H
#include <stdlib.h>
...
...
@@ -18,9 +19,7 @@
#include "TrigInDetAnalysis/TrackSelector.h"
#include "TrigInDetAnalysisUtils/Filters.h"
#include "TrigInDetAnalysisUtils/Filter_Offline2017.h"
#include "TrigInDetAnalysisExample/NtupleTrackSelector.h"
#include "RoiFilter.h"
#include "utils.h"
#include "TrigInDetAnalysis/TrackSelector.h"
#include "TrigInDetAnalysis/TrigObjectMatcher.h"
#include "TH1D.h"
...
...
@@ -33,7 +32,7 @@
#include "TrigInDetAnalysis/TIDDirectory.h"
#include "TrigInDetAnalysis/Efficiency.h"
#include "TrigInDetAnalysis/TIDARoiDescriptor.h"
#include "TrigInDetAnalysisExample/ChainString.h"
class
TagNProbe
{
...
...
@@ -47,7 +46,7 @@ public:
/// configuration methods
void
SetEventConfiguration
(
Ntuple
TrackSelector
*
refTracks
,
// reference tracks
TrackSelector
*
refTracks
,
// reference tracks
TrackFilter
*
refFilter
,
// reference filter
std
::
string
refName
,
// reference objects name
TrigObjectMatcher
*
tom
,
// trigger object matcher
...
...
@@ -81,7 +80,7 @@ public:
void
SetObjMatcher
(
TrigObjectMatcher
*
tom
)
{
m_tom
=
tom
;
}
void
SetOfflineTracks
(
Ntuple
TrackSelector
*
refTracks
,
TrackFilter
*
refFilter
)
{
void
SetOfflineTracks
(
TrackSelector
*
refTracks
,
TrackFilter
*
refFilter
)
{
m_refTracks
=
refTracks
;
m_refFilter
=
refFilter
;
}
...
...
@@ -142,7 +141,7 @@ protected:
private:
Ntuple
TrackSelector
*
m_refTracks
;
TrackSelector
*
m_refTracks
;
TrackFilter
*
m_refFilter
;
TIDA
::
Chain
*
m_chain
;
...
...
@@ -172,4 +171,4 @@ private:
};
#endif // TIDA_TAGNPROBE_H
#endif // TIDA
UTILS
_TAGNPROBE_H
Trigger/TrigAnalysis/TrigInDetAnalysisU
ser/Analysi
s/src/TagNProbe.cxx
→
Trigger/TrigAnalysis/TrigInDetAnalysisU
til
s/src/TagNProbe.cxx
View file @
e8522ac6
...
...
@@ -7,7 +7,9 @@
** Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
**/
#include "TagNProbe.h"
#include "TrigInDetAnalysisUtils/TagNProbe.h"
double
TagNProbe
::
computeZ_obj
(
TIDA
::
Track
*
t1
,
TIDA
::
Track
*
t2
)
{
...
...
@@ -195,12 +197,9 @@ void TagNProbe::FillMap( std::vector<std::string>& tnpChains ) {
for
(
size_t
i
=
0
;
i
<
tnpChains
.
size
()
-
1
;
i
+=
2
)
{
ChainS
tring
chain_tag
=
ChainString
(
tnpChains
[
i
]
);
ChainS
tring
chain_probe
=
ChainString
(
tnpChains
[
i
+
1
]
);
std
::
s
tring
chain_tag
_name
=
(
tnpChains
[
i
]).
substr
(
0
,
(
tnpChains
[
i
]).
find
(
":post"
)
);
std
::
s
tring
chain_probe
_name
=
(
tnpChains
[
i
+
1
]).
substr
(
0
,
(
tnpChains
[
i
+
1
]).
find
(
":post"
)
);
std
::
string
chain_tag_name
=
chain_tag
.
pre
();
std
::
string
chain_probe_name
=
chain_probe
.
pre
();
m_tnp_map
.
insert
(
std
::
map
<
std
::
string
,
std
::
string
>::
value_type
(
chain_probe_name
,
chain_tag_name
)
);
/// new testChain vector is filled only with probe chain names
...
...
@@ -275,8 +274,8 @@ std::vector<TIDA::Roi*> TagNProbe::GetRois( TIDA::Chain * chain, std::vector<TID
void
TagNProbe
::
BookMinvHisto
(
std
::
string
chain_name
)
{
std
::
string
hname_base
=
chain_name
;
replace
(
hname_base
,
'/'
,
'_'
);
replace
(
hname_base
,
':'
,
'_'
);
std
::
replace
(
hname_base
.
begin
(),
hname_base
.
end
()
,
'/'
,
'_'
);
std
::
replace
(
hname_base
.
begin
(),
hname_base
.
end
()
,
':'
,
'_'
);
std
::
string
hname_1
=
hname_base
+
"_Minv_TnP"
;
std
::
string
hname_2
=
hname_base
+
"_Minv_obj_TnP"
;
...
...
@@ -318,8 +317,8 @@ void TagNProbe::WriteMinvHisto( TDirectory* foutdir ) {
for
(
hMinv_itr
=
m_hMinv_map
.
begin
()
;
hMinv_itr
!=
m_hMinv_map
.
end
()
;
hMinv_itr
++
)
{
std
::
string
dirname
=
hMinv_itr
->
first
;
replace
(
dirname
,
'/'
,
'_'
);
replace
(
dirname
,
':'
,
'_'
);
std
::
replace
(
dirname
.
begin
(),
dirname
.
end
()
,
'/'
,
'_'
);
std
::
replace
(
dirname
.
begin
(),
dirname
.
end
()
,
':'
,
'_'
);
std
::
string
dirpath
(
foutdir
->
GetPath
()
);
dirpath
+=
dirname
;
...
...
@@ -338,8 +337,8 @@ void TagNProbe::WriteMinvHisto( TDirectory* foutdir ) {
for
(
hMinv_obj_itr
=
m_hMinv_obj_map
.
begin
()
;
hMinv_obj_itr
!=
m_hMinv_obj_map
.
end
()
;
hMinv_obj_itr
++
)
{
std
::
string
dirname
=
hMinv_obj_itr
->
first
;
replace
(
dirname
,
'/'
,
'_'
);
replace
(
dirname
,
':'
,
'_'
);
std
::
replace
(
dirname
.
begin
(),
dirname
.
end
()
,
'/'
,
'_'
);
std
::
replace
(
dirname
.
begin
(),
dirname
.
end
()
,
':'
,
'_'
);
std
::
string
dirpath
(
foutdir
->
GetPath
()
);
dirpath
+=
dirname
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment