4.7.4. thuner.data.synthetic

Module for generating synthetic reflectivity data for testing. This module a work in progress; core functions are very slow.

Functions

create_object(time, center_latitude, ...[, ...])

Create a dictionary containing the object properties.

pydantic model thuner.data.synthetic.SyntheticOptions[source]

Bases: BaseDatasetOptions

Class for managing the options for the synthetic dataset.

Fields:
Validators:

field end: str = '2005-11-14T00:00:00'
field fields: list[str] = ['reflectivity']
field name: str = 'synthetic'
field start: str = '2005-11-13T00:00:00'
field starting_objects: list[dict] | None = None
field type: Literal['SyntheticOptions'] = 'SyntheticOptions'
field use: str = 'track'
get_filepaths()[source]

Override the get_filepaths method to return an empty list, as filepaths not relevant for synthetic data.

update_input_record(time, input_record, track_options, grid_options)[source]

Update the synthetic dataset.

thuner.data.synthetic.create_object(time, center_latitude, center_longitude, direction, speed, horizontal_radius=20, alt_center=3000.0, alt_radius=1000.0, intensity=50, eccentricity=0.4, orientation=0.7853981633974483)[source]

Create a dictionary containing the object properties.

Parameters:
  • time (str) – The time at which the object has the properties in the dictionary.

  • center_latitude (float) – The latitude of the center of the object.

  • center_longitude (float) – The longitude of the center of the object.

  • direction (float) – The direction the object is moving in radians clockwise from north.

  • speed (float) – The speed the object is moving in metres per second.

  • horizontal_radius (float, optional) – The horizontal radius of the object in km; default is 20.

Returns:

object_dict – Dictionary containing the object properties.

Return type:

dict