ATLAS Offline Software
Loading...
Searching...
No Matches
external_photos.py
Go to the documentation of this file.
1# Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
2
3from AthenaCommon import Logging
4from .external_base import ExternalBase
5
6
7logger = Logging.logging.getLogger("PowhegControl")
8
9
11 """! Class for running external PHOTOS process.
12
13 @author James Robinson <james.robinson@cern.ch>
14 """
15
16 def __init__(self, *args):
17 """! Constructor.
18
19 @param process PHOTOS process
20 """
21 super(ExternalPHOTOS, self).__init__("PHOTOS", *args)
22
23 # Add parameters used by PHOTOS
24 self.add_keyword("PHOTOS_enabled")
25
26 def needs_scheduling(self, process):
27 """! Report whether the PHOTOS process should be scheduled.
28
29 @param process PowhegBox process.
30 """
31 # Check that PHOTOS is not disabled
32 self.expose()
34 logger.info("Running with PHOTOS enabled")
35 else:
36 logger.info("Running without PHOTOS")
37 return False
38 return True
add_keyword(self, keyword, value=None, name=None, frozen=None, hidden=None, description=None, **kwargs)
Register configurable parameter that is exposed to the user.
expose(self)
Add all names to the interface of this object.
Class for running external PHOTOS process.
needs_scheduling(self, process)
Report whether the PHOTOS process should be scheduled.