trajectory_supervisor.supervisor_modules.supmod_friction.src.supmod_friction module

class trajectory_supervisor.supervisor_modules.supmod_friction.src.supmod_friction.SupModFriction(supmod_config_path: str, veh_params: dict, localgg: numpy.ndarray)[source]

Bases: object

Class handling safety checks regarding given friction / acceleration limits.

Authors
Created on

14.11.2019

Init the SupMod.

Parameters
  • supmod_config_path – path to Supervisor config file

  • veh_params

    dict of vehicle parameters; must hold the following keys: dyn_model_exp - exponent used in vehicle dynamics model (usual range [1.0, 2.0])

    NOTE: 2.0 -> ideal friction circle; 1.0 -> perfect diamond shape

    drag_coeff - drag coeff. incl. all constants (0.5 * c_w * A_front * rho_air)

    set zero to disable [in m2*kg/m3]

    m_veh - vehicle mass [in kg]

  • localgg – track specific acceleration limits as numpy array with columns [x, y, s_m, ax, ay] NOTE: currently only the maximum of ax and ay is used globally (worst case estimate)

calc_score(ego_data: numpy.ndarray)tuple[source]

Asses the trajectory safety for a given time instance regarding given acceleration limits :param ego_data: data of the ego vehicle(s, pos_x, pos_y, heading, curvature, velocity, acceleration)

for a given time instance

Returns

  • safety - binary value indicating the safety state. ‘False’ = unsafe and ‘True’ = safe

  • safety_parameters - parameter dict