openworld_radio_twin.simulation.antenna_placement#

Place antenna records in a compiled scene as Sionna-ready transmitters.

Every interface (the Python loader, the web service, dataset generation and the built-in Sionna engine) places antennas through this module, so a transmitter taken from a source has the same position and orientation wherever it is used.

Functions

complete_antennas(result[, defaults])

Fill the values a source does not give and set each antenna's Sionna orientation.

keep_inside_scene(result, assets)

Keep the antennas inside a compiled scene's square and count the others.

keep_inside_square(result, longitude, ...)

Keep the antennas inside the square around a centre and count the others.

place_antennas(result, assets[, defaults])

Keep antennas inside the scene square and complete them as Sionna transmitters.

sionna_orientation(azimuth_deg, downtilt_deg)

Sionna's rotation angles (alpha, beta, gamma) in radians for a compass bearing.

openworld_radio_twin.simulation.antenna_placement.sionna_orientation(azimuth_deg, downtilt_deg)[source]#

Sionna’s rotation angles (alpha, beta, gamma) in radians for a compass bearing.

Sionna rotates the antenna boresight to (cos a cos b, sin a cos b, -sin b) in the scene’s east, north and up axes. A compass azimuth, clockwise from north, is therefore alpha = 90 degrees - azimuth, and a positive downtilt is beta.

Return type:

tuple[float, float, float]

openworld_radio_twin.simulation.antenna_placement.keep_inside_square(result, longitude, latitude, radius_m)[source]#

Keep the antennas inside the square around a centre and count the others.

Return type:

AntennaQueryResult

openworld_radio_twin.simulation.antenna_placement.keep_inside_scene(result, assets)[source]#

Keep the antennas inside a compiled scene’s square and count the others.

Return type:

AntennaQueryResult

openworld_radio_twin.simulation.antenna_placement.complete_antennas(result, defaults=None)[source]#

Fill the values a source does not give and set each antenna’s Sionna orientation.

Values come from defaults and are marked default; a value the source gives counts as source unless the provider marked it otherwise. This needs no scene, so a map can show antennas before one is compiled; place_antennas() adds the scene position.

Return type:

AntennaQueryResult

openworld_radio_twin.simulation.antenna_placement.place_antennas(result, assets, defaults=None)[source]#

Keep antennas inside the scene square and complete them as Sionna transmitters.

Values the source does not give come from defaults and are marked default. An antenna that would sit inside a building of this scene is raised above its roof by defaults.roof_clearance_m and its height is marked adjusted: register heights and building heights come from different sources, and a transmitter enclosed by a building shell would produce an empty radio map.

Return type:

AntennaQueryResult