RAVE
Lib.tiled_compositing.tiled_compositing Class Reference

The actual compositing instance forwarding requests to the tilers. More...

Inheritance diagram for Lib.tiled_compositing.tiled_compositing:

Public Member Functions

 __init__ (self, c, preprocess_qc=False, mp_process_qc=False, mp_process_qc_split_evenly=False)
 Constructor.
 
 generate (self, dd, dt, area=None)
 Same as compositing generate but this is supposed to forward requests to a tiling mechanism.
 

Public Attributes

 compositing = c
 
 preprocess_qc = preprocess_qc
 
 mp_process_qc = mp_process_qc
 
 mp_process_qc_split_evenly = mp_process_qc_split_evenly
 
 verbose = c.verbose
 
 logger = logger
 
dict file_objects = {}
 
str nodes = ""
 
str how_tasks = ""
 
 number_of_quality_control_processes = RAVE_QUALITY_CONTROL_PROCESSES
 
 mpname = multiprocessing.current_process().name
 

Protected Member Functions

 _fetch_file_objects (self)
 Fetches the file objects and if self.preprocess_qc is True performs the quality controls.
 
 _fetch_file_objects_mp (self)
 Fetches the file objects including the quality control by utilizing the multiprocessing capabilities.
 
 _create_multi_composite_argument (self, adef=None)
 Creates the composite arguments that should be sent to one tiler.
 
 _create_tiled_area_definition (self, pyarea)
 Creates an area definition used for passing to the tiler.
 
 _create_arguments (self, dd, dt, pyarea)
 Creates the list of arguments to be sent to the tilers.
 
 _add_files_to_argument_list (self, args, tiled_areas)
 
 _add_radar_index_value_to_argument_list (self, args)
 
 _ensure_date_and_time_on_args (self, args)
 
 _create_lon_lat_extent (self, carg)
 

Protected Attributes

bool _do_remove_temporary_files = False
 

Detailed Description

The actual compositing instance forwarding requests to the tilers.

Constructor & Destructor Documentation

◆ __init__()

Lib.tiled_compositing.tiled_compositing.__init__ ( self,
c,
preprocess_qc = False,
mp_process_qc = False,
mp_process_qc_split_evenly = False )

Constructor.

Parameters
cthe compositing instance
preprocess_qcIf the ingoing files should be preprocessed or not before they are sent to the tile generators (might improve performance in some cases)
mp_process_qcIf preprocess_qc is True, then this flag will send the files to separate processes for quality control execution
mp_process_qc_split_evenlyOf mp_process_qc is True, then this flag will indicate if the incomming files should be splitted evenly between the processes. If false, then one file at a time are handled.

Member Function Documentation

◆ _create_arguments()

Lib.tiled_compositing.tiled_compositing._create_arguments ( self,
dd,
dt,
pyarea )
protected

Creates the list of arguments to be sent to the tilers.

Each item in the returned list is supposed to represent one tile

Parameters
dddate
dttime
aidthe area id (that might or not be tiled)
Returns
a list of argument lists

◆ _create_multi_composite_argument()

Lib.tiled_compositing.tiled_compositing._create_multi_composite_argument ( self,
adef = None )
protected

Creates the composite arguments that should be sent to one tiler.

Parameters
adefthe area definition
Returns
the composite argument instance

◆ _create_tiled_area_definition()

Lib.tiled_compositing.tiled_compositing._create_tiled_area_definition ( self,
pyarea )
protected

Creates an area definition used for passing to the tiler.

Parameters
pyareathe python c area object
Returns
the area defintion

◆ _fetch_file_objects()

Lib.tiled_compositing.tiled_compositing._fetch_file_objects ( self)
protected

Fetches the file objects and if self.preprocess_qc is True performs the quality controls.

If quality control processing is performed successfully, then temporary files are created and their removal is required if self._do_remove_temporary_files = True

Returns
(a dictionary with filenames as keys and objects as values, and a string with all included nodes names)

◆ _fetch_file_objects_mp()

Lib.tiled_compositing.tiled_compositing._fetch_file_objects_mp ( self)
protected

Fetches the file objects including the quality control by utilizing the multiprocessing capabilities.

I.e. instead of performing the fetching and quality controls within this process. This job is spawned of to separate processors that manages the qc. This will generate a number of temporary files that should be removed if self._do_remove_temporary_files=True

Returns
(a dictionary with filenames as keys and objects as values, and a string with all included nodes names)

◆ generate()

Lib.tiled_compositing.tiled_compositing.generate ( self,
dd,
dt,
area = None )

Same as compositing generate but this is supposed to forward requests to a tiling mechanism.

Parameters
dddate
dttime
areathe area id

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