Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
athena
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michael Donald Hank
athena
Commits
c7dacb49
Commit
c7dacb49
authored
2 months ago
by
Antonio De Maria
Committed by
Walter Lampl
2 months ago
Browse files
Options
Downloads
Patches
Plain Diff
cleanup of TauAODMuonRemovalTool
cleanup of TauAODMuonRemovalTool
parent
0272163c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Reconstruction/tauRecTools/Root/TauAODMuonRemovalTool.cxx
+2
-15
2 additions, 15 deletions
Reconstruction/tauRecTools/Root/TauAODMuonRemovalTool.cxx
Reconstruction/tauRecTools/tauRecTools/TauAODMuonRemovalTool.h
+1
-2
1 addition, 2 deletions
...struction/tauRecTools/tauRecTools/TauAODMuonRemovalTool.h
with
3 additions
and
17 deletions
Reconstruction/tauRecTools/Root/TauAODMuonRemovalTool.cxx
+
2
−
15
View file @
c7dacb49
...
...
@@ -61,7 +61,7 @@ StatusCode TauAODMuonRemovalTool::execute(xAOD::TauJet& tau) const {
}
//helpers
std
::
vector
<
const
xAOD
::
CaloCluster
*>
TauAODMuonRemovalTool
::
getOrignalTopoClusters
(
const
xAOD
::
CaloCluster
*
cluster
)
const
{
std
::
vector
<
const
xAOD
::
CaloCluster
*>
TauAODMuonRemovalTool
::
getOrig
i
nalTopoClusters
(
const
xAOD
::
CaloCluster
*
cluster
)
const
{
static
const
SG
::
Accessor
<
std
::
vector
<
ElementLink
<
xAOD
::
CaloClusterContainer
>>>
acc_origClusterLinks
(
"constituentClusterLinks"
);
std
::
vector
<
const
xAOD
::
CaloCluster
*
>
orig_cls
;
if
(
acc_origClusterLinks
.
isAvailable
(
*
cluster
))
{
...
...
@@ -76,19 +76,6 @@ std::vector<const xAOD::CaloCluster*> TauAODMuonRemovalTool::getOrignalTopoClust
return
orig_cls
;
}
const
xAOD
::
TrackParticle
*
TauAODMuonRemovalTool
::
getOrignalTrackParticle
(
const
xAOD
::
TrackParticle
*
trk
)
const
{
static
const
SG
::
Accessor
<
ElementLink
<
xAOD
::
TrackParticleContainer
>>
acc_origTracks
(
"originalTrackParticle"
);
const
xAOD
::
TrackParticle
*
orig_trk
=
nullptr
;
if
(
acc_origTracks
.
isAvailable
(
*
trk
))
{
if
(
const
auto
&
orig_link
=
acc_origTracks
(
*
trk
);
orig_link
.
isValid
())
{
if
(
orig_link
.
dataID
()
!=
"InDetTrackParticles"
)
ATH_MSG_WARNING
(
"the tracks in the lepton cannot be converted to InDetTrackParticles, the ID is "
<<
orig_link
.
dataID
());
orig_trk
=
*
orig_link
;
}
}
return
orig_trk
;
}
std
::
vector
<
std
::
pair
<
const
xAOD
::
TrackParticle
*
,
const
xAOD
::
Muon
*>>
TauAODMuonRemovalTool
::
getMuonAndTrk
(
const
xAOD
::
TauJet
&
tau
,
const
xAOD
::
MuonContainer
&
muon_container
)
const
{
std
::
vector
<
std
::
pair
<
const
xAOD
::
TrackParticle
*
,
const
xAOD
::
Muon
*>>
ret
;
std
::
for_each
(
muon_container
.
cbegin
(),
muon_container
.
cend
(),
...
...
@@ -114,7 +101,7 @@ std::vector<std::pair<const xAOD::CaloCluster*, const xAOD::Muon*>> TauAODMuonRe
auto
cls_e
=
muon_cluster
->
e
();
auto
loss_diff
=
((
cls_e
-
loss_e
)
/
(
cls_e
+
loss_e
));
if
(
muon_e
>
cls_e
&&
loss_diff
<
0.1
&&
loss_diff
>
-
0.3
)
{
auto
orig_muon_clusters
=
getOrignalTopoClusters
(
muon_cluster
);
auto
orig_muon_clusters
=
getOrig
i
nalTopoClusters
(
muon_cluster
);
for
(
auto
cluster
:
orig_muon_clusters
)
ret
.
push_back
(
std
::
make_pair
(
cluster
,
muon
));
}
...
...
This diff is collapsed.
Click to expand it.
Reconstruction/tauRecTools/tauRecTools/TauAODMuonRemovalTool.h
+
1
−
2
View file @
c7dacb49
...
...
@@ -34,8 +34,7 @@ class TauAODMuonRemovalTool : public TauRecToolBase
Gaudi
::
Property
<
std
::
string
>
m_strMinMuonIdWp
{
this
,
"muonIDWP"
,
"Medium"
,
"minimum muon identification WP, [VeryLoose, Loose, Medium, Tight]"
};
Gaudi
::
Property
<
double
>
m_lepRemovalConeSize
{
this
,
"lepRemovalConeSize"
,
0.6
,
"The maximum dR between the lepton and the tau"
};
//helpers
std
::
vector
<
const
xAOD
::
CaloCluster
*>
getOrignalTopoClusters
(
const
xAOD
::
CaloCluster
*
cluster
)
const
;
const
xAOD
::
TrackParticle
*
getOrignalTrackParticle
(
const
xAOD
::
TrackParticle
*
trk
)
const
;
std
::
vector
<
const
xAOD
::
CaloCluster
*>
getOriginalTopoClusters
(
const
xAOD
::
CaloCluster
*
cluster
)
const
;
std
::
vector
<
std
::
pair
<
const
xAOD
::
TrackParticle
*
,
const
xAOD
::
Muon
*>>
getMuonAndTrk
(
const
xAOD
::
TauJet
&
tau
,
const
xAOD
::
MuonContainer
&
muon_cont
)
const
;
std
::
vector
<
std
::
pair
<
const
xAOD
::
CaloCluster
*
,
const
xAOD
::
Muon
*>>
getMuonAndCls
(
const
xAOD
::
TauJet
&
tau
,
const
xAOD
::
MuonContainer
&
muon_cont
)
const
;
template
<
typename
Tlep
,
typename
Tlinks
>
std
::
vector
<
Tlep
>
removeTrks
(
Tlinks
&
tau_trk_links
,
std
::
vector
<
std
::
pair
<
const
xAOD
::
TrackParticle
*
,
Tlep
>>&
removings
)
const
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment