Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
athena
Manage
Activity
Members
Labels
Plan
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review 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
atlas
athena
Commits
cf8cb5a2
Commit
cf8cb5a2
authored
1 year ago
by
Jackson Carl Burzynski
Committed by
Jackson Carl Burzynski
11 months ago
Browse files
Options
Downloads
Patches
Plain Diff
update to use Decorators
parent
10e37375
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!70762
2024-04-22: merge of 24.0 into main
,
!63422
Add tool for fitting GN2 vertices
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Reconstruction/VKalVrt/GNNVertexConstructor/Root/GNNVertexConstructorTool.cxx
+10
-9
10 additions, 9 deletions
...rt/GNNVertexConstructor/Root/GNNVertexConstructorTool.cxx
with
10 additions
and
9 deletions
Reconstruction/VKalVrt/GNNVertexConstructor/Root/GNNVertexConstructorTool.cxx
+
10
−
9
View file @
cf8cb5a2
...
...
@@ -80,6 +80,11 @@ StatusCode GNNVertexConstructorTool::performVertexFit(const xAOD::JetContainer *
vertexLinksHandle
(
m_vertexLinksKey
,
ctx
);
SG
::
WriteDecorHandle
<
xAOD
::
JetContainer
,
std
::
vector
<
ElementLink
<
xAOD
::
VertexContainer
>>>
jetWriteDecorHandleVertexLink
(
m_jetWriteDecorKeyVertexLink
,
ctx
);
// Vertex decorators
SG
::
AuxElement
::
Decorator
<
float
>
decor_mass
(
"mass"
);
SG
::
AuxElement
::
Decorator
<
float
>
decor_pT
(
"pt"
);
SG
::
AuxElement
::
Decorator
<
float
>
decor_charge
(
"charge"
);
SG
::
AuxElement
::
Decorator
<
float
>
decor_vPos
(
"vPos"
);
// Create a map of track links and track vertexing values (Using mutlimap)
std
::
multimap
<
int
,
TL
>
vertexMap
;
...
...
@@ -87,7 +92,6 @@ StatusCode GNNVertexConstructorTool::performVertexFit(const xAOD::JetContainer *
// Loop over the jets
for
(
const
auto
&
jet
:
*
inJetContainer
)
{
vertexMap
.
clear
();
auto
vertexCollection
=
vertexLinksHandle
(
*
jet
);
...
...
@@ -149,7 +153,6 @@ StatusCode GNNVertexConstructorTool::performVertexFit(const xAOD::JetContainer *
vDist
.
z
()
*
newvrt
.
vertexMom
.
Pz
())
/
newvrt
.
vertexMom
.
Rho
();
// @Luke TODO: need to add the tracks to the vertex
xAOD
::
Vertex
*
GNNvertex
=
new
xAOD
::
Vertex
;
outVertexContainer
->
emplace_back
(
GNNvertex
);
...
...
@@ -165,18 +168,16 @@ StatusCode GNNVertexConstructorTool::performVertexFit(const xAOD::JetContainer *
GNNvertex
->
setVertexType
(
xAOD
::
VxType
::
SecVtx
);
GNNvertex
->
setPosition
(
newvrt
.
vertex
);
GNNvertex
->
setFitQuality
(
newvrt
.
chi2
,
1
);
GNNvertex
->
auxdata
<
float
>
(
"mass"
)
=
newvrt
.
vertexMom
.
M
();
GNNvertex
->
auxdata
<
float
>
(
"pT"
)
=
newvrt
.
vertexMom
.
Perp
();
GNNvertex
->
auxdata
<
float
>
(
"charge"
)
=
newvrt
.
vertex
Charge
;
GNNvertex
->
auxdata
<
float
>
(
"vPos"
)
=
vPos
;
GNNvertex
->
auxdata
<
bool
>
(
"isFake"
)
=
true
;
decor_mass
(
*
GNNvertex
)
=
newvrt
.
vertexMom
.
M
();
decor_pT
(
*
GNNvertex
)
=
newvrt
.
vertex
Mom
.
Perp
()
;
decor_charge
(
*
GNNvertex
)
=
newvrt
.
vertexCharge
;
decor_vPos
(
*
GNNvertex
)
=
vPos
;
ElementLink
<
xAOD
::
VertexContainer
>
linkVertex
;
linkVertex
.
setElement
(
GNNvertex
);
linkVertex
.
setStorableObject
(
*
outVertexContainer
);
jetWriteDecorHandleVertexLink
(
*
jet
).
push_back
(
linkVertex
);
// @Luke TODO: build vertex links and add to jet
}
}
delete
xAODwrk
;
...
...
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