ATLAS Offline Software
Loading...
Searching...
No Matches
Generators
PowhegControl
python
algorithms
postprocessors
output_tarball_preparer.py
Go to the documentation of this file.
1
# Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
2
3
from
AthenaCommon
import
Logging
4
from
...decorators
import
timed
5
import
subprocess
6
7
8
logger = Logging.logging.getLogger(
"PowhegControl"
)
9
10
11
@timed("output tarball preparer")
12
def
output_tarball_preparer(output_events_name, output_tarball_name):
13
"""! Tar events if LHE output is requested.
14
15
@param output_events_name LHE events file name.
16
@param output_tarball_name Tar-ed LHE file name.
17
18
@author James Robinson <james.robinson@cern.ch>
19
"""
20
logger.info(
"Tar-ing output events into {}"
.format(output_tarball_name))
21
for
line
in
subprocess.check_output([
"tar"
,
"cvzf"
, output_tarball_name, output_events_name], stderr=subprocess.STDOUT).splitlines():
22
logger.info(line)
Generated on
for ATLAS Offline Software by
1.14.0