Belle II Software  release-05-02-19
Basf2CalculationProcess Class Reference
Inheritance diagram for Basf2CalculationProcess:
Collaboration diagram for Basf2CalculationProcess:

Public Member Functions

def __init__ (self, result_queue, log_file_name, parameters, path, random_seed=None, max_event=0)
 
def prepare (self)
 
def initialize_output (self)
 
def start_process (self)
 
def save_log (self)
 
def get_log (self)
 
def get (self, name)
 
def get_keys (self)
 

Public Attributes

 random_seed
 Random seed to set. More...
 
 path
 Path to process.
 
 max_event
 The maximum number of events to process. More...
 
 is_valid
 Set is_valid to false to not show this process in any listings.
 
 already_run
 True if already started/run.
 
 log_file_name
 Name of the log file to use.
 
 log_file_content
 Saved log file content after the run.
 
 result_queue
 Result queue as a reference.
 
 parameters
 Parameters in process_parameter_space.
 
 progress_queue_remote
 Create the queue for the progress python module.
 

Detailed Description

Overload implementation of the HEPProcess with the correct handling of the path calculation.

Definition at line 11 of file calculation_process.py.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  result_queue,
  log_file_name,
  parameters,
  path,
  random_seed = None,
  max_event = 0 
)
Create a new basf2 calculation process.

Definition at line 17 of file calculation_process.py.

17  def __init__(self, result_queue, log_file_name, parameters, path, random_seed=None, max_event=0):
18  """Create a new basf2 calculation process."""
19 
20  self.random_seed = random_seed
21 
22  self.path = path
23 
24  self.max_event = max_event
25 
26  super(Basf2CalculationProcess, self).__init__(result_queue=result_queue, log_file_name=log_file_name,
27  parameters=parameters)
28 

Member Function Documentation

◆ get()

def get (   self,
  name 
)
inherited
Return an item from the result queue. Only gives a result if the calculation has finished.
Use the Calculation for a better handling.

Definition at line 69 of file calculation_process.py.

◆ get_keys()

def get_keys (   self)
inherited
Return the names of all item from the result queue. Only gives a result if the calculation has finished.
Use the Calculation for a better handling.

Definition at line 77 of file calculation_process.py.

◆ get_log()

def get_log (   self)
inherited
Return the log file content.
Use the methods of the Calculation for a better handling.

Definition at line 58 of file calculation_process.py.

◆ initialize_output()

def initialize_output (   self)
Make sure all output by python and or C is written to the same output file

Definition at line 44 of file calculation_process.py.

◆ prepare()

def prepare (   self)
A function to prepare a path with the modules given in path.

Reimplemented from CalculationProcess.

Definition at line 29 of file calculation_process.py.

◆ save_log()

def save_log (   self)
inherited
Delete the log file and copy its content to the class.

Definition at line 49 of file calculation_process.py.

◆ start_process()

def start_process (   self)
The function given to the process to start the calculation.
Do not call by yourself.
Resets the logging system, logs onto console and a file and sets the queues
(the result queue and the process queue) correctly.

Reimplemented from CalculationProcess.

Definition at line 64 of file calculation_process.py.

Member Data Documentation

◆ max_event

max_event

The maximum number of events to process.

Leave 0 to process al events

Definition at line 24 of file calculation_process.py.

◆ random_seed

random_seed

Random seed to set.

None will not set it.

Definition at line 20 of file calculation_process.py.


The documentation for this class was generated from the following file: