Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
athena
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
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
Alex Veltman
athena
Commits
3d80560b
Commit
3d80560b
authored
7 years ago
by
Vakhtang Tsulaia
Browse files
Options
Downloads
Patches
Plain Diff
Fixed unnecessary reopening of input files in EvtRangeProcessor (ES only)
parent
302b99ea
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
Control/AthenaMPTools/src/EvtRangeProcessor.cxx
+16
-0
16 additions, 0 deletions
Control/AthenaMPTools/src/EvtRangeProcessor.cxx
Control/AthenaMPTools/src/EvtRangeProcessor.h
+1
-0
1 addition, 0 deletions
Control/AthenaMPTools/src/EvtRangeProcessor.h
with
17 additions
and
0 deletions
Control/AthenaMPTools/src/EvtRangeProcessor.cxx
+
16
−
0
View file @
3d80560b
...
...
@@ -47,6 +47,7 @@ EvtRangeProcessor::EvtRangeProcessor(const std::string& type
,
m_isPileup
(
false
)
,
m_rankId
(
-
1
)
,
m_nEventsBeforeFork
(
0
)
,
m_inpFile
(
""
)
,
m_chronoStatSvc
(
"ChronoStatSvc"
,
name
)
,
m_incidentSvc
(
"IncidentSvc"
,
name
)
,
m_evtSeek
(
0
)
...
...
@@ -721,6 +722,8 @@ StatusCode EvtRangeProcessor::startProcess()
StatusCode
EvtRangeProcessor
::
setNewInputFile
(
const
std
::
string
&
newFile
)
{
if
(
m_inpFile
==
newFile
)
return
StatusCode
::
SUCCESS
;
// Get Property Server
IProperty
*
propertyServer
=
dynamic_cast
<
IProperty
*>
(
m_evtSelector
);
if
(
!
propertyServer
)
{
...
...
@@ -729,12 +732,25 @@ StatusCode EvtRangeProcessor::setNewInputFile(const std::string& newFile)
}
std
::
string
propertyName
(
"InputCollections"
);
if
(
m_inpFile
.
empty
())
{
std
::
vector
<
std
::
string
>
vect
;
StringArrayProperty
inputFileList
(
propertyName
,
vect
);
if
(
propertyServer
->
getProperty
(
&
inputFileList
).
isFailure
())
{
ATH_MSG_ERROR
(
"Failed to get InputCollections property value of the Event Selector"
);
return
StatusCode
::
FAILURE
;
}
if
(
newFile
==
inputFileList
.
value
()[
0
])
{
m_inpFile
=
newFile
;
return
StatusCode
::
SUCCESS
;
}
}
std
::
vector
<
std
::
string
>
vect
{
newFile
,};
StringArrayProperty
newInputFileList
(
propertyName
,
vect
);
if
(
propertyServer
->
setProperty
(
newInputFileList
).
isFailure
())
{
ATH_MSG_ERROR
(
"Unable to update "
<<
newInputFileList
.
name
()
<<
" property on the Event Selector"
);
return
StatusCode
::
FAILURE
;
}
m_inpFile
=
newFile
;
return
StatusCode
::
SUCCESS
;
}
...
...
This diff is collapsed.
Click to expand it.
Control/AthenaMPTools/src/EvtRangeProcessor.h
+
1
−
0
View file @
3d80560b
...
...
@@ -63,6 +63,7 @@ class EvtRangeProcessor : public AthenaMPToolBase
bool
m_isPileup
;
// Are we doing pile-up digitization?
int
m_rankId
;
// Each worker has its own unique RankID from the range (0,...,m_nprocs-1)
int
m_nEventsBeforeFork
;
std
::
string
m_inpFile
;
// Cached name of the input file. To avoid reopening
ServiceHandle
<
IChronoStatSvc
>
m_chronoStatSvc
;
ServiceHandle
<
IIncidentSvc
>
m_incidentSvc
;
...
...
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