CARLA
Namespaces | Macros | Variables
Constants.h File Reference
#include <limits>
#include <stdint.h>
#include <iostream>
#include <vector>
+ Include dependency graph for Constants.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 carla
 This file contains definitions of common data structures used in traffic manager.
 
 carla::traffic_manager
 
 carla::traffic_manager::constants
 
 carla::traffic_manager::constants::Collision
 
 carla::traffic_manager::constants::FrameMemory
 
 carla::traffic_manager::constants::HybridMode
 
 carla::traffic_manager::constants::LaneChange
 
 carla::traffic_manager::constants::Map
 
 carla::traffic_manager::constants::MotionPlan
 
 carla::traffic_manager::constants::Networking
 
 carla::traffic_manager::constants::PathBufferUpdate
 
 carla::traffic_manager::constants::PID
 
 carla::traffic_manager::constants::SpeedThreshold
 
 carla::traffic_manager::constants::TrackTraffic
 
 carla::traffic_manager::constants::TrafficLight
 
 carla::traffic_manager::constants::VehicleLight
 
 carla::traffic_manager::constants::VehicleRemoval
 
 carla::traffic_manager::constants::WaypointSelection
 

Macros

#define RATE(MaxY, MinY, DiffX)   (((MaxY) - (MinY)) / (DiffX))
 
#define SQUARE(a)   ((a) * (a))
 This file contains various constants used in traffic manager arranged into sensible namespaces for re-usability across different files. More...
 

Variables

static const float carla::traffic_manager::constants::SpeedThreshold::AFTER_JUNCTION_MIN_SPEED = 5.0f / 3.6f
 
static const uint16_t carla::traffic_manager::constants::MotionPlan::ATTEMPTS_TO_TELEPORT = 5u
 
static const double carla::traffic_manager::constants::VehicleRemoval::BLOCKED_TIME_THRESHOLD = 90.0
 
static const float carla::traffic_manager::constants::Collision::BOUNDARY_EXTENSION_MINIMUM = 2.5f
 
static const float carla::traffic_manager::constants::Collision::BOUNDARY_EXTENSION_RATE = 4.35f
 
static const uint64_t carla::traffic_manager::constants::TrackTraffic::BUFFER_STEP_THROUGH = 5
 
static const float carla::traffic_manager::constants::Collision::COLLISION_RADIUS_MIN = 20.0f
 
static const float carla::traffic_manager::constants::Collision::COLLISION_RADIUS_RATE = 2.65f
 
static const float carla::traffic_manager::constants::Collision::COLLISION_RADIUS_STOP = 8.0f
 
static const float carla::traffic_manager::constants::Collision::COS_10_DEGREES = 0.9848f
 
static const float carla::traffic_manager::constants::MotionPlan::CRITICAL_BRAKING_MARGIN = 0.2f
 
static float const carla::traffic_manager::constants::Map::DELTA = 25.0f
 
static const double carla::traffic_manager::constants::VehicleRemoval::DELTA_TIME_BETWEEN_DESTRUCTIONS = 10.0
 
static const double carla::traffic_manager::constants::TrafficLight::DOUBLE_NO_SIGNAL_PASSTHROUGH_INTERVAL = 5.0
 
static const float carla::traffic_manager::constants::PID::DT = 0.05f
 
static const float carla::traffic_manager::constants::Collision::EPSILON = 2.0f * std::numeric_limits<float>::epsilon()
 
static const float carla::traffic_manager::constants::MotionPlan::EPSILON_RELATIVE_SPEED = 0.001f
 
static const float carla::traffic_manager::constants::LaneChange::FIFTYPERC = 50.0f
 
static const float carla::traffic_manager::constants::VehicleLight::FOG_DENSITY_THRESHOLD = 20.0f
 
static const float carla::traffic_manager::constants::MotionPlan::FOLLOW_LEAD_FACTOR = 2.0f
 
static const float carla::traffic_manager::constants::MotionPlan::FRICTION = 0.6f
 
static const float carla::traffic_manager::constants::MotionPlan::GRAVITY = 9.81f
 
static const uint64_t carla::traffic_manager::constants::FrameMemory::GROWTH_STEP_SIZE = 50u
 
static const float carla::traffic_manager::constants::VehicleLight::HEAVY_PRECIPITATION_THRESHOLD = 80.0f
 
static const float carla::traffic_manager::constants::PathBufferUpdate::HIGH_SPEED_HORIZON_RATE = 4.0f
 
static const float carla::traffic_manager::constants::SpeedThreshold::HIGHWAY_SPEED = 60.0f / 3.6f
 
static const float carla::traffic_manager::constants::PathBufferUpdate::HORIZON_RATE = 2.0f
 
static const double carla::traffic_manager::constants::HybridMode::HYBRID_MODE_DT = 0.1
 
static const float carla::traffic_manager::constants::HybridMode::HYBRID_MODE_DT_FL = 0.1f
 
static const float carla::traffic_manager::constants::Map::INFINITE_DISTANCE = std::numeric_limits<float>::max()
 
static const float carla::traffic_manager::constants::SpeedThreshold::INITIAL_PERCENTAGE_SPEED_DIFFERENCE = 0.0f
 
static const uint64_t carla::traffic_manager::constants::FrameMemory::INITIAL_SIZE = 50u
 
static const float carla::traffic_manager::constants::LaneChange::INTER_LANE_CHANGE_DISTANCE = 10.0f
 
static const float carla::traffic_manager::constants::TrackTraffic::INV_BUFFER_STEP_THROUGH = 1.0f / static_cast<float>(BUFFER_STEP_THROUGH)
 
static const float carla::traffic_manager::constants::PID::INV_DT = 1.0f / DT
 
static const float carla::traffic_manager::constants::FrameMemory::INV_GROWTH_STEP_SIZE = 1.0f / static_cast<float>(GROWTH_STEP_SIZE)
 
static const double carla::traffic_manager::constants::HybridMode::INV_HYBRID_DT = 1.0 / HYBRID_MODE_DT
 
static const float carla::traffic_manager::constants::Map::INV_MAP_RESOLUTION = 1.0f / MAP_RESOLUTION
 
static const float carla::traffic_manager::constants::WaypointSelection::JUNCTION_LOOK_AHEAD = 5.0f
 
static const float carla::traffic_manager::constants::MotionPlan::LANDMARK_DETECTION_TIME = 2.5f
 
static const std::vector< float > carla::traffic_manager::constants::PID::LATERAL_HIGHWAY_PARAM = {2.0f, 0.02f, 0.04f}
 
static const std::vector< float > carla::traffic_manager::constants::PID::LATERAL_PARAM = {4.0f, 0.02f, 0.08f}
 
static const float carla::traffic_manager::constants::Collision::LOCKING_DISTANCE_PADDING = 4.0f
 
static const std::vector< float > carla::traffic_manager::constants::PID::LONGITUDIAL_HIGHWAY_PARAM = {20.0f, 0.05f, 0.01f}
 
static const std::vector< float > carla::traffic_manager::constants::PID::LONGITUDIAL_PARAM = {12.0f, 0.05f, 0.02f}
 
static const float carla::traffic_manager::constants::Map::MAP_RESOLUTION = 5.0f
 
static const float carla::traffic_manager::constants::PID::MAX_BRAKE = 0.7f
 
static const float carla::traffic_manager::constants::VehicleLight::MAX_DISTANCE_LIGHT_CHECK = 225.0f
 
static const float carla::traffic_manager::constants::Map::MAX_GEODESIC_GRID_LENGTH = 20.0f
 
static const float carla::traffic_manager::constants::MotionPlan::MAX_JUNCTION_BLOCK_DISTANCE = 1.0f * WaypointSelection::SAFE_DISTANCE_AFTER_JUNCTION
 
static const float carla::traffic_manager::constants::Collision::MAX_LOCKING_EXTENSION = 10.0f
 
static const float carla::traffic_manager::constants::PathBufferUpdate::MAX_START_DISTANCE = 20.0f
 
static const float carla::traffic_manager::constants::PID::MAX_STEERING = 0.8f
 
static const float carla::traffic_manager::constants::PID::MAX_STEERING_DIFF = 0.15f
 
static const float carla::traffic_manager::constants::PID::MAX_THROTTLE = 0.85f
 
static const float carla::traffic_manager::constants::LaneChange::MAX_WPT_DISTANCE = 20.0f
 
static const double carla::traffic_manager::constants::Map::MAX_WPT_DISTANCE = MAP_RESOLUTION/2.0 + SQUARE(MAP_RESOLUTION)
 
static const float carla::traffic_manager::constants::Map::MAX_WPT_RADIANS = 0.087f
 
static const float carla::traffic_manager::constants::LaneChange::MAXIMUM_LANE_OBSTACLE_CURVATURE = 0.6f
 
static const float carla::traffic_manager::constants::LaneChange::MAXIMUM_LANE_OBSTACLE_DISTANCE = 50.0f
 
static const float carla::traffic_manager::constants::MotionPlan::MIN_FOLLOW_LEAD_DISTANCE = 2.0f
 
static const float carla::traffic_manager::constants::WaypointSelection::MIN_JUNCTION_LENGTH = 8.0f
 
static const float carla::traffic_manager::constants::LaneChange::MIN_LANE_CHANGE_SPEED = 5.0f
 
static const float carla::traffic_manager::constants::Collision::MIN_REFERENCE_DISTANCE = 0.5f
 
static const float carla::traffic_manager::constants::WaypointSelection::MIN_SAFE_INTERVAL_LENGTH = 0.5f * SAFE_DISTANCE_AFTER_JUNCTION
 
static const float carla::traffic_manager::constants::WaypointSelection::MIN_TARGET_WAYPOINT_DISTANCE = 3.0f
 
static const uint64_t carla::traffic_manager::constants::Networking::MIN_TRY_COUNT = 20u
 
static const float carla::traffic_manager::constants::Collision::MIN_VELOCITY_COLL_RADIUS = 2.0f
 
static const float carla::traffic_manager::constants::LaneChange::MIN_WPT_DISTANCE = 5.0f
 
static const float carla::traffic_manager::constants::PathBufferUpdate::MINIMUM_HORIZON_LENGTH = 15.0f
 
static const float carla::traffic_manager::constants::LaneChange::MINIMUM_LANE_CHANGE_DISTANCE = 20.0f
 
static const uint64_t carla::traffic_manager::constants::TrafficLight::NO_SIGNAL_PASSTHROUGH_INTERVAL = 5u
 
static const float carla::traffic_manager::constants::Collision::OVERLAP_THRESHOLD = 0.1f
 
static const float carla::traffic_manager::constants::MotionPlan::PERC_MAX_SLOWDOWN = 0.08f
 
static const float carla::traffic_manager::constants::HybridMode::PHYSICS_RADIUS = 50.0f
 
static const float carla::traffic_manager::constants::MotionPlan::PI = 3.1415927f
 
static const double carla::traffic_manager::constants::VehicleRemoval::RED_TL_BLOCKED_TIME_THRESHOLD = 180.0
 
static const float carla::traffic_manager::constants::MotionPlan::RELATIVE_APPROACH_SPEED = 12.0f / 3.6f
 
static const float carla::traffic_manager::constants::WaypointSelection::SAFE_DISTANCE_AFTER_JUNCTION = 4.0f
 
static const float carla::traffic_manager::constants::Collision::SQUARE_ROOT_OF_TWO = 1.414f
 
static const float carla::traffic_manager::constants::MotionPlan::STOP_TARGET_VELOCITY = 15.0f / 3.6f
 
static const float carla::traffic_manager::constants::VehicleRemoval::STOPPED_VELOCITY_THRESHOLD = 0.8f
 
static float const carla::traffic_manager::constants::Map::STRAIGHT_DEG = 19.0f
 
static const float carla::traffic_manager::constants::VehicleLight::SUN_ALTITUDE_DEGREES_AFTER_SUNSET = 165.0f
 
static const float carla::traffic_manager::constants::VehicleLight::SUN_ALTITUDE_DEGREES_BEFORE_DAWN = 15.0f
 
static const float carla::traffic_manager::constants::VehicleLight::SUN_ALTITUDE_DEGREES_JUST_AFTER_DAWN = 35.0f
 
static const float carla::traffic_manager::constants::VehicleLight::SUN_ALTITUDE_DEGREES_JUST_BEFORE_SUNSET = 145.0f
 
static const float carla::traffic_manager::constants::WaypointSelection::TARGET_WAYPOINT_TIME_HORIZON = 0.3f
 
static const float carla::traffic_manager::constants::MotionPlan::TL_GREEN_TARGET_VELOCITY = 20.0f / 3.6f
 
static const float carla::traffic_manager::constants::MotionPlan::TL_RED_TARGET_VELOCITY = 15.0f / 3.6f
 
static const float carla::traffic_manager::constants::MotionPlan::TL_UNKNOWN_TARGET_VELOCITY = TL_RED_TARGET_VELOCITY
 
static const unsigned short carla::traffic_manager::constants::Networking::TM_DEFAULT_PORT = 8000u
 
static const int64_t carla::traffic_manager::constants::Networking::TM_TIMEOUT = 2000
 
static const float carla::traffic_manager::constants::MotionPlan::TWO_KM = 2000.0f
 
static const float carla::traffic_manager::constants::Collision::VEL_EXT_FACTOR = 0.36f
 
static const float carla::traffic_manager::constants::Collision::VERTICAL_OVERLAP_THRESHOLD = 4.0f
 
static const float carla::traffic_manager::constants::Collision::WALKER_TIME_EXTENSION = 1.5f
 
static const float carla::traffic_manager::constants::MotionPlan::YIELD_TARGET_VELOCITY = 15.0f / 3.6f
 
static float const carla::traffic_manager::constants::Map::Z_DELTA = 500.0f
 

Macro Definition Documentation

◆ RATE

#define RATE (   MaxY,
  MinY,
  DiffX 
)    (((MaxY) - (MinY)) / (DiffX))

Definition at line 14 of file Constants.h.

◆ SQUARE

#define SQUARE (   a)    ((a) * (a))