Updated changelog. Updated Python documentation.
This commit is contained in:
parent
d5c57e8903
commit
f2130d1ef4
|
@ -7,6 +7,7 @@
|
|||
* Added walkable pedestrian crosswalks in OpenDRIVE standalone mode
|
||||
* Improved mesh generation with a chunk system for better performance and bigger maps in the future
|
||||
* Added security features to the standalone OpenDRIVE mode aiming to prevent cars from falling down from the road
|
||||
* Added junction smoothing algorithm to prevent roads from blocking other roads with level differences
|
||||
* Added new Behavior agent
|
||||
* Added automatic generation of traffic lights, stop signal and yield signal from OpenDRIVE file
|
||||
* Upgraded to AD RSS v3.0.0 supporting complex road layouts and i.e. intersections
|
||||
|
|
|
@ -1075,6 +1075,25 @@ Distance between `actor` and `other`.
|
|||
|
||||
---
|
||||
|
||||
## carla.OpendriveGenerationParameters<a name="carla.OpendriveGenerationParameters"></a>
|
||||
This class defines the parameters used when generating a world using an OpenDRIVE file.
|
||||
|
||||
<h3>Instance Variables</h3>
|
||||
- <a name="carla.OpendriveGenerationParameters.vertex_distance"></a>**<font color="#f8805a">vertex_distance</font>**
|
||||
The distance between vertices when generating the world mesh from OpenDRIVE.
|
||||
- <a name="carla.OpendriveGenerationParameters.max_road_length"></a>**<font color="#f8805a">max_road_length</font>**
|
||||
Max road length for a single mesh portion.
|
||||
- <a name="carla.OpendriveGenerationParameters.wall_height"></a>**<font color="#f8805a">wall_height</font>**
|
||||
Defines the height of walls added to roads to prevent vehicles from falling.
|
||||
- <a name="carla.OpendriveGenerationParameters.additional_width"></a>**<font color="#f8805a">additional_width</font>**
|
||||
Additional with to junction lanes to prevent vehicles from falling.
|
||||
- <a name="carla.OpendriveGenerationParameters.smooth_junctions"></a>**<font color="#f8805a">smooth_junctions</font>**
|
||||
When this variable is `True` the generated junctions will be smoothed to prevent roads from blocking other roads.
|
||||
- <a name="carla.OpendriveGenerationParameters.enable_mesh_visibility"></a>**<font color="#f8805a">enable_mesh_visibility</font>**
|
||||
This variable indicates whether the mesh should be rendered to reduce the rendering overhead.
|
||||
|
||||
---
|
||||
|
||||
## carla.RadarDetection<a name="carla.RadarDetection"></a>
|
||||
Data contained inside a [carla.RadarMeasurement](#carla.RadarMeasurement). Each of these represents one of the points in the cloud that a <b>sensor.other.radar</b> registers and contains the distance, angle and velocity in relation to the radar.
|
||||
|
||||
|
@ -1445,7 +1464,7 @@ All possible states for traffic lights. These can either change at a specific ti
|
|||
---
|
||||
|
||||
## carla.TrafficManager<a name="carla.TrafficManager"></a>
|
||||
The traffic manager is a module built on top of the CARLA API in C++. It handles any group of vehicles set to autopilot mode to populate the simulation with realistic urban traffic conditions and give the chance to user to customize some behaviours. The architecture of the traffic manager is divided in five different goal-oriented stages and a PID controller where the information flows until eventually, a [carla.VehicleControl](#carla.VehicleControl) is applied to every vehicle registered in a traffic manager.
|
||||
The traffic manager is a module built on top of the CARLA API in C++. It handles any group of vehicles set to autopilot mode to populate the simulation with realistic urban traffic conditions and give the chance to user to customize some behaviours. The architecture of the traffic manager is divided in five different goal-oriented stages and a PID controller where the information flows until eventually, a [carla.VehicleControl](#carla.VehicleControl) is applied to every vehicle registered in a traffic manager.
|
||||
In order to learn more, visit the [documentation](adv_traffic_manager.md) regarding this module.
|
||||
|
||||
<h3>Methods</h3>
|
||||
|
@ -1475,7 +1494,7 @@ Sets the minimum distance in meters that vehicles have to keep with the rest. Th
|
|||
- **Parameters:**
|
||||
- `distance` (_float_) – Meters between vehicles.
|
||||
- <a name="carla.TrafficManager.global_percentage_speed_difference"></a>**<font color="#7fb800">global_percentage_speed_difference</font>**(<font color="#00a6ed">**self**</font>, <font color="#00a6ed">**percentage**</font>)
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
Default is 30. Exceeding a speed limit can be done using negative percentages.
|
||||
- **Parameters:**
|
||||
- `percentage` (_float_) – Percentage difference between intended speed and the current limit.
|
||||
|
@ -1497,7 +1516,7 @@ During the collision detection stage, which runs every frame, this method sets a
|
|||
- <a name="carla.TrafficManager.reset_traffic_lights"></a>**<font color="#7fb800">reset_traffic_lights</font>**(<font color="#00a6ed">**self**</font>)
|
||||
Resets every traffic light in the map to its initial state.
|
||||
- <a name="carla.TrafficManager.vehicle_percentage_speed_difference"></a>**<font color="#7fb800">vehicle_percentage_speed_difference</font>**(<font color="#00a6ed">**self**</font>, <font color="#00a6ed">**actor**</font>, <font color="#00a6ed">**percentage**</font>)
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
Default is 30. Exceeding a speed limit can be done using negative percentages.
|
||||
- **Parameters:**
|
||||
- `actor` (_[carla.Actor](#carla.Actor)_) – Vehicle whose speed behaviour is being changed.
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
- param_name: commands
|
||||
type: list
|
||||
doc: >
|
||||
A list of commands to execute in batch. Each command is different and has its own parameters. They appear listed at the bottom of this page.
|
||||
A list of commands to execute in batch. Each command is different and has its own parameters. They appear listed at the bottom of this page.
|
||||
doc: >
|
||||
Executes a list of commands on a single simulation step and retrieves no information. If you need information about the response of each command, use the **<font color="#7fb800">apply_batch_sync()</font>** function right below this one.
|
||||
[Here](https://github.com/carla-simulator/carla/blob/10c5f6a482a21abfd00220c68c7f12b4110b7f63/PythonAPI/examples/spawn_npc.py#L126) is an example on how to delete the actors that appear in carla.ActorList all at once.
|
||||
|
@ -55,7 +55,7 @@
|
|||
type: bool
|
||||
default: false
|
||||
doc: >
|
||||
A boolean parameter to specify whether or not to perform a carla.World.tick after applying the batch in _synchronous mode_. It is __False__ by default.
|
||||
A boolean parameter to specify whether or not to perform a carla.World.tick after applying the batch in _synchronous mode_. It is __False__ by default.
|
||||
return: list(command.Response)
|
||||
doc: >
|
||||
Executes a list of commands on a single simulation step, blocks until the commands are linked, and returns a list of <b>command.Response</b> that can be used to determine whether a single command succeeded or not. [Here](https://github.com/carla-simulator/carla/blob/10c5f6a482a21abfd00220c68c7f12b4110b7f63/PythonAPI/examples/spawn_npc.py#L112-L116) is an example of it being used to spawn actors.
|
||||
|
@ -233,10 +233,10 @@
|
|||
type: int
|
||||
default: 8000
|
||||
doc: >
|
||||
Port that will be used by the traffic manager. Default is `8000`.
|
||||
Port that will be used by the traffic manager. Default is `8000`.
|
||||
return: carla.TrafficManager
|
||||
doc: >
|
||||
Returns an instance of the traffic manager related to the specified port. If it does not exist, this will be created.
|
||||
Returns an instance of the traffic manager related to the specified port. If it does not exist, this will be created.
|
||||
# --------------------------------------
|
||||
- def_name: get_world
|
||||
params:
|
||||
|
@ -267,8 +267,8 @@
|
|||
- class_name: TrafficManager
|
||||
# - DESCRIPTION ------------------------
|
||||
doc: >
|
||||
The traffic manager is a module built on top of the CARLA API in C++. It handles any group of vehicles set to autopilot mode to populate the simulation with realistic urban traffic conditions and give the chance to user to customize some behaviours. The architecture of the traffic manager is divided in five different goal-oriented stages and a PID controller where the information flows until eventually, a carla.VehicleControl is applied to every vehicle registered in a traffic manager.
|
||||
|
||||
The traffic manager is a module built on top of the CARLA API in C++. It handles any group of vehicles set to autopilot mode to populate the simulation with realistic urban traffic conditions and give the chance to user to customize some behaviours. The architecture of the traffic manager is divided in five different goal-oriented stages and a PID controller where the information flows until eventually, a carla.VehicleControl is applied to every vehicle registered in a traffic manager.
|
||||
|
||||
In order to learn more, visit the [documentation](adv_traffic_manager.md) regarding this module.
|
||||
# - PROPERTIES -------------------------
|
||||
instance_variables:
|
||||
|
@ -283,16 +283,16 @@
|
|||
- param_name: enable
|
||||
type: bool
|
||||
doc: >
|
||||
__True__ is default and enables lane changes. __False__ will disable them.
|
||||
__True__ is default and enables lane changes. __False__ will disable them.
|
||||
doc: >
|
||||
Turns on or off lane changing behaviour for a vehicle.
|
||||
Turns on or off lane changing behaviour for a vehicle.
|
||||
# --------------------------------------
|
||||
- def_name: collision_detection
|
||||
params:
|
||||
- param_name: reference_actor
|
||||
type: carla.Actor
|
||||
doc: >
|
||||
Vehicle that is going to ignore collisions.
|
||||
Vehicle that is going to ignore collisions.
|
||||
- param_name: other_actor
|
||||
type: carla.Actor
|
||||
doc: >
|
||||
|
@ -300,7 +300,7 @@
|
|||
- param_name: detect_collision
|
||||
type: bool
|
||||
doc: >
|
||||
__True__ is default and enables collisions. __False will disable them.
|
||||
__True__ is default and enables collisions. __False will disable them.
|
||||
doc: >
|
||||
Tunes on/off collisions between a vehicle and another specific actor. In order to ignore all other vehicles, traffic lights or walkers, use the specific __ignore__ methods described in this same section.
|
||||
# --------------------------------------
|
||||
|
@ -309,11 +309,11 @@
|
|||
- param_name: actor
|
||||
type: carla.Actor
|
||||
doc: >
|
||||
Vehicle whose minimum distance is being changed.
|
||||
Vehicle whose minimum distance is being changed.
|
||||
- param_name: distance
|
||||
type: float
|
||||
doc: >
|
||||
Meters between both vehicles.
|
||||
Meters between both vehicles.
|
||||
doc: >
|
||||
Sets the minimum distance in meters that a vehicle has to keep with the others. The distance is in meters and will affect the minimum moving distance. It is computed from front to back of the vehicle objects.
|
||||
# --------------------------------------
|
||||
|
@ -322,20 +322,20 @@
|
|||
- param_name: actor
|
||||
type: carla.Actor
|
||||
doc: >
|
||||
Vehicle being forced to change lanes.
|
||||
Vehicle being forced to change lanes.
|
||||
- param_name: direction
|
||||
type: bool
|
||||
doc: >
|
||||
Destination lane. __True__ is the one on the left and __False__ is the right one.
|
||||
doc: >
|
||||
Destination lane. __True__ is the one on the left and __False__ is the right one.
|
||||
doc: >
|
||||
Forces a vehicle to change either to the lane on its left or right, if existing, as indicated in `direction`. This method applies the lane change no matter what, disregarding possible collisions.
|
||||
Forces a vehicle to change either to the lane on its left or right, if existing, as indicated in `direction`. This method applies the lane change no matter what, disregarding possible collisions.
|
||||
# --------------------------------------
|
||||
- def_name: global_distance_to_leading_vehicle
|
||||
params:
|
||||
- param_name: distance
|
||||
type: float
|
||||
doc: >
|
||||
Meters between vehicles.
|
||||
Meters between vehicles.
|
||||
doc: >
|
||||
Sets the minimum distance in meters that vehicles have to keep with the rest. The distance is in meters and will affect the minimum moving distance. It is computed from center to center of the vehicle objects.
|
||||
# --------------------------------------
|
||||
|
@ -346,9 +346,9 @@
|
|||
doc: >
|
||||
Percentage difference between intended speed and the current limit.
|
||||
doc: >
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
|
||||
Default is 30. Exceeding a speed limit can be done using negative percentages.
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
|
||||
Default is 30. Exceeding a speed limit can be done using negative percentages.
|
||||
# --------------------------------------
|
||||
- def_name: ignore_lights_percentage
|
||||
params:
|
||||
|
@ -361,7 +361,7 @@
|
|||
doc: >
|
||||
Between 0 and 100. Amount of times traffic lights will be ignored.
|
||||
doc: >
|
||||
During the traffic light stage, which runs every frame, this method sets the percent chance that traffic lights will be ignored for a vehicle.
|
||||
During the traffic light stage, which runs every frame, this method sets the percent chance that traffic lights will be ignored for a vehicle.
|
||||
# --------------------------------------
|
||||
- def_name: ignore_vehicles_percentage
|
||||
params:
|
||||
|
@ -372,7 +372,7 @@
|
|||
- param_name: perc
|
||||
type: float
|
||||
doc: >
|
||||
Between 0 and 100. Amount of times collisions will be ignored.
|
||||
Between 0 and 100. Amount of times collisions will be ignored.
|
||||
doc: >
|
||||
During the collision detection stage, which runs every frame, this method sets a percent chance that collisions with another vehicle will be ignored for a vehicle.
|
||||
# --------------------------------------
|
||||
|
@ -385,28 +385,28 @@
|
|||
- param_name: perc
|
||||
type: float
|
||||
doc: >
|
||||
Between 0 and 100. Amount of times collisions will be ignored.
|
||||
Between 0 and 100. Amount of times collisions will be ignored.
|
||||
doc: >
|
||||
During the collision detection stage, which runs every frame, this method sets a percent chance that collisions with walkers will be ignored for a vehicle.
|
||||
# --------------------------------------
|
||||
- def_name: reset_traffic_lights
|
||||
doc: >
|
||||
Resets every traffic light in the map to its initial state.
|
||||
Resets every traffic light in the map to its initial state.
|
||||
# --------------------------------------
|
||||
- def_name: vehicle_percentage_speed_difference
|
||||
params:
|
||||
- param_name: actor
|
||||
type: carla.Actor
|
||||
doc: >
|
||||
Vehicle whose speed behaviour is being changed.
|
||||
Vehicle whose speed behaviour is being changed.
|
||||
- param_name: percentage
|
||||
type: float
|
||||
doc: >
|
||||
Percentage difference between intended speed and the current limit.
|
||||
Percentage difference between intended speed and the current limit.
|
||||
doc: >
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
|
||||
Default is 30. Exceeding a speed limit can be done using negative percentages.
|
||||
Sets the difference the vehicle's intended speed and its current speed limit. Speed limits can be exceeded by setting the `perc` to a negative value.
|
||||
|
||||
Default is 30. Exceeding a speed limit can be done using negative percentages.
|
||||
# --------------------------------------
|
||||
- def_name: set_hybrid_physics_mode
|
||||
params:
|
||||
|
@ -428,3 +428,28 @@
|
|||
doc: >
|
||||
With hybrid physics on, changes the radius of the area of influence where physics are enabled.
|
||||
# --------------------------------------
|
||||
|
||||
- class_name: OpendriveGenerationParameters
|
||||
# - DESCRIPTION ------------------------
|
||||
doc: >
|
||||
This class defines the parameters used when generating a world using an OpenDRIVE file.
|
||||
# - PROPERTIES -------------------------
|
||||
instance_variables:
|
||||
- var_name: vertex_distance
|
||||
doc: >
|
||||
The distance between vertices when generating the world mesh from OpenDRIVE.
|
||||
- var_name: max_road_length
|
||||
doc: >
|
||||
Max road length for a single mesh portion.
|
||||
- var_name: wall_height
|
||||
doc: >
|
||||
Defines the height of walls added to roads to prevent vehicles from falling.
|
||||
- var_name: additional_width
|
||||
doc: >
|
||||
Additional with to junction lanes to prevent vehicles from falling.
|
||||
- var_name: smooth_junctions
|
||||
doc: >
|
||||
When this variable is `True` the generated junctions will be smoothed to prevent roads from blocking other roads.
|
||||
- var_name: enable_mesh_visibility
|
||||
doc: >
|
||||
This variable indicates whether the mesh should be rendered to reduce the rendering overhead.
|
||||
|
|
Loading…
Reference in New Issue