MCPcopy Create free account

hub / github.com/DongChen06/MARL_CAVs / functions

Functions435 in github.com/DongChen06/MARL_CAVs

↓ 2 callersMethodhandle_event
Map the pygame keyboard events to control decisions :param action_type: the ActionType that defines how the vehicle is controlled
highway-env/highway_env/envs/common/graphics.py:153
↓ 2 callersFunctionhas_corner_inside
Check if rect1 has a corner inside rect2 :param rect1: (center, length, width, angle) :param rect2: (center, length, width, angle)
highway-env/highway_env/utils.py:101
↓ 2 callersFunctionidm_controller
(vehicle, env_copy, action)
highway-env/highway_env/envs/common/idm_controller.py:41
↓ 2 callersFunctioninit_dir
(base_dir, pathes=['train_videos', 'configs', 'models', 'eval_videos', 'eval_logs'])
MARL/common/utils.py:151
↓ 2 callersFunctionintegrator_interval
Compute the interval of an integrator system: dx = -k*x :param x: state interval :param k: gain interval, must be positive :return:
highway-env/highway_env/interval.py:62
↓ 2 callersMethodinteract
(self)
MARL/MAPPO.py:97
↓ 2 callersFunctioninterval_negative_part
Compute the negative part of an interval :param a: interval [a_min, a_max] :return: the interval of its negative part min(a, 0)
highway-env/highway_env/interval.py:52
↓ 2 callersFunctionintervals_scaling
Scale an intervals :param a: matrix a :param b: interval [b_min, b_max] :return: the interval of their product ab
highway-env/highway_env/interval.py:26
↓ 2 callersFunctionis_metzler
(matrix: np.ndarray, eps: float = 1e-9)
highway-env/highway_env/interval.py:145
↓ 2 callersMethodlateral_lpv_dynamics
State: [lateral speed v, yaw rate r] :return: lateral dynamics A, B
highway-env/highway_env/vehicle/dynamics.py:139
↓ 2 callersMethodlateral_lpv_structure
State: [lateral speed v, yaw rate r] :return: lateral dynamics A0, phi, B such that dx = (A0 + theta^T phi)x + B u
highway-env/highway_env/vehicle/dynamics.py:108
↓ 2 callersFunctionobservation_factory
(env: 'AbstractEnv', config: dict)
highway-env/highway_env/envs/common/observation.py:384
↓ 2 callersMethodobserver_step
Step the interval observer dynamics :param dt: timestep [s]
highway-env/highway_env/vehicle/uncertainty/prediction.py:93
↓ 2 callersMethodon_state_update
(self)
highway-env/highway_env/vehicle/kinematics.py:153
↓ 2 callersMethodpolytope_from_estimation
(self, data: dict, parameter_box: np.ndarray, structure: Callable[[], Polytope])
highway-env/highway_env/vehicle/uncertainty/estimation.py:22
↓ 2 callersMethodpredict_trajectory_constant_speed
Predict the future positions of the vehicle along its planned route, under constant speed :param times: timesteps of prediction
highway-env/highway_env/vehicle/controller.py:186
↓ 2 callersFunctionrun
()
MARL/run_madqn.py:30
↓ 2 callersMethodspeed_control
Control the speed of the vehicle. Using a simple proportional controller. :param target_speed: the desired speed :re
highway-env/highway_env/vehicle/controller.py:143
↓ 2 callersMethodstep
Perform an action and step the environment dynamics. The action is executed by the ego-vehicle, and all other vehicles on the road p
highway-env/highway_env/envs/common/abstract.py:440
↓ 2 callersMethodstep
(self, dt: float, mode: str = "partial")
highway-env/highway_env/vehicle/uncertainty/prediction.py:81
↓ 2 callersMethodtrain
(self)
MARL/MADQN.py:115
↓ 2 callersFunctionupdate_running_stat
(aa, m_aa, momentum)
MARL/single_agent/kfac.py:66
↓ 2 callersMethodvehicle_class
The class of a vehicle able to execute the action. Must return a subclass of :py:class:`highway_env.vehicle.kinematics.Vehicle`.
highway-env/highway_env/envs/common/action.py:28
↓ 1 callersMethod__init__
(self, road: Road, position: List[float], heading: float =
highway-env/highway_env/vehicle/controller.py:206
↓ 1 callersMethod__init__
(self, road: Road, position: Vector, heading: float = 0,
highway-env/highway_env/vehicle/behavior.py:42
↓ 1 callersMethod__init__
New sinusoidal lane. :param start: the lane starting position [m] :param end: the lane ending position [m] :param am
highway-env/highway_env/road/lane.py:175
↓ 1 callersMethod__init__
(self, module)
MARL/single_agent/kfac.py:74
↓ 1 callersMethod__str__
(self)
highway-env/highway_env/vehicle/kinematics.py:262
↓ 1 callersMethod__str__
(self)
highway-env/highway_env/road/objects.py:77
↓ 1 callersMethod_agent_is_terminal
The episode is over when a collision occurs or when the access ramp has been passed.
highway-env/highway_env/envs/merge_env_v1.py:149
↓ 1 callersMethod_automatic_rendering
Automatically render the intermediate frames while an action is still ongoing. This allows to render the whole video and not only si
highway-env/highway_env/envs/common/abstract.py:591
↓ 1 callersMethod_cost
A constraint metric, for budgeted MDP. If a constraint is defined, it must be used with an alternate reward that doesn't contain it
highway-env/highway_env/envs/common/abstract.py:163
↓ 1 callersMethod_discount_reward
(self, rewards, final_value)
MARL/MAACKTR.py:291
↓ 1 callersMethod_discount_reward
(self, rewards, final_value)
MARL/MAPPO.py:314
↓ 1 callersMethod_discount_reward
(self, rewards, final_value)
MARL/single_agent/Agent_common.py:130
↓ 1 callersMethod_make_road
Make a road composed of a straight highway and a merging lane. :return: the road
highway-env/highway_env/envs/merge_env_v1.py:184
↓ 1 callersMethod_make_vehicles
Populate a road with several vehicles on the highway and on the merging lane, as well as an ego-vehicle. :return: the ego-vehicle
highway-env/highway_env/envs/merge_env_v1.py:212
↓ 1 callersMethod_prepare_model
(self)
MARL/single_agent/kfac.py:177
↓ 1 callersMethod_record_to_grayscale
(self)
highway-env/highway_env/envs/common/observation.py:86
↓ 1 callersMethod_regional_reward
(self)
highway-env/highway_env/envs/merge_env_v1.py:90
↓ 1 callersMethod_reset
Reset the scene: roads and vehicles. This method must be overloaded by the environments.
highway-env/highway_env/envs/common/abstract.py:208
↓ 1 callersMethod_reward
Return the reward associated with performing a given action and ending up in the current state. :param action: the last action perfo
highway-env/highway_env/envs/common/abstract.py:146
↓ 1 callersMethod_simulate
Perform several steps of simulation with constant action.
highway-env/highway_env/envs/common/abstract.py:506
↓ 1 callersMethodact
Store an action to be repeated. :param action: the input action
highway-env/highway_env/vehicle/kinematics.py:113
↓ 1 callersMethodact
Execute an action. For now, no action is supported because the vehicle takes all decisions of acceleration and lane changes
highway-env/highway_env/vehicle/behavior.py:74
↓ 1 callersFunctionagg_double_list
(l)
MARL/single_agent/utils_common.py:46
↓ 1 callersMethodbfs_paths
Breadth-first search of all routes from start to goal. :param start: starting node :param goal: goal node :return: l
highway-env/highway_env/road/road.py:111
↓ 1 callersMethodblit_rotate
Many thanks to https://stackoverflow.com/a/54714144.
highway-env/highway_env/road/graphics.py:309
↓ 1 callersFunctionchange_lane_policy
Decide when to change lane. Based on: - frequency; - closeness of the target lane; - MOBIL model.
highway-env/highway_env/envs/common/idm_controller.py:87
↓ 1 callersMethodchange_lane_policy
Decide when to change lane. Based on: - frequency; - closeness of the target lane; - MOBIL model.
highway-env/highway_env/vehicle/behavior.py:186
↓ 1 callersMethodcheck_safety_room
para: vehicle: the ego vehicle surrounding_vehicles: [v_fl, v_rl, v_fr, v_rr] env_copy: copy of self
highway-env/highway_env/envs/common/abstract.py:239
↓ 1 callersFunctionclip_actions
(action, speed, crashed)
highway-env/highway_env/envs/common/mdp_controller.py:118
↓ 1 callersFunctionclip_actions
(action, speed, crashed)
highway-env/highway_env/envs/common/idm_controller.py:230
↓ 1 callersMethodclip_actions
(self)
highway-env/highway_env/vehicle/kinematics.py:142
↓ 1 callersMethodclip_actions
(self)
highway-env/highway_env/vehicle/dynamics.py:102
↓ 1 callersMethodcollect_data
Store features and outputs for parameter regression.
highway-env/highway_env/vehicle/behavior.py:452
↓ 1 callersFunctioncompute_cov_a
(a, classname, layer_info, fast_cnn)
MARL/single_agent/kfac.py:28
↓ 1 callersFunctioncompute_cov_g
(g, classname, layer_info, fast_cnn)
MARL/single_agent/kfac.py:48
↓ 1 callersFunctionconfidence_ellipsoid
Compute a confidence ellipsoid over the parameter theta, where y = theta^T phi :param data: a dictionary {"features": [phi_0,...,phi_N], "ou
highway-env/highway_env/utils.py:123
↓ 1 callersMethodcontinuous_curve
Draw a striped line on one side of a lane, on a surface. :param lane: the lane :param surface: the pygame surface :p
highway-env/highway_env/road/graphics.py:153
↓ 1 callersMethodcontinuous_line
Draw a continuous line on one side of a lane, on a surface. :param lane: the lane :param surface: the pygame surface
highway-env/highway_env/road/graphics.py:170
↓ 1 callersFunctioncopy_file_akctr
(tar_dir)
MARL/common/utils.py:130
↓ 1 callersFunctioncopy_file_ppo
(tar_dir)
MARL/common/utils.py:109
↓ 1 callersMethoddefault_config
(cls)
highway-env/highway_env/envs/merge_env_v1.py:31
↓ 1 callersMethoddefault_config
Default environment configuration. Can be overloaded in environment implementations, or by calling configure(). :return: a c
highway-env/highway_env/envs/common/abstract.py:97
↓ 1 callersMethoddisplay
Display the road and vehicles on a pygame window.
highway-env/highway_env/envs/common/graphics.py:92
↓ 1 callersMethoddisplay_history
Display the whole trajectory of a vehicle on a pygame surface. :param vehicle: the vehicle states within the trajectory to be displa
highway-env/highway_env/vehicle/graphics.py:125
↓ 1 callersMethoddisplay_road_objects
Display the road objects on a surface. :param road: the road to be displayed :param surface: the pygame surface :par
highway-env/highway_env/road/graphics.py:260
↓ 1 callersMethoddisplay_traffic
Display the road vehicles on a surface. :param road: the road to be displayed :param surface: the pygame surface :pa
highway-env/highway_env/road/graphics.py:243
↓ 1 callersMethoddisplay_trajectory
Display the whole trajectory of a vehicle on a pygame surface. :param states: the list of vehicle states within the trajectory to be
highway-env/highway_env/vehicle/graphics.py:113
↓ 1 callersMethoddistance_with_heading
Compute a weighted distance in position and heading to the lane.
highway-env/highway_env/road/lane.py:102
↓ 1 callersMethodenforce_road_rules
Find conflicts and resolve them by assigning yielding vehicles and stopping them.
highway-env/highway_env/road/regulation.py:27
↓ 1 callersFunctionentropy
(p)
MARL/common/utils.py:9
↓ 1 callersFunctionevaluate
(args)
MARL/run_maacktr.py:149
↓ 1 callersFunctionevaluate
(args)
MARL/run_mappo.py:155
↓ 1 callersMethodevaluation
(self, env, eval_episodes=10)
MARL/MADQN.py:179
↓ 1 callersMethodexploration_action
(self, state, n_agents)
MARL/MAACKTR.py:197
↓ 1 callersMethodexploration_action
(self, state, n_agents)
MARL/MAPPO.py:216
↓ 1 callersMethodexploration_action
(self, state)
MARL/MADQN.py:154
↓ 1 callersFunctionfinite_mdp
Time-To-Collision (TTC) representation of the state. The state reward is defined from a occupancy grid over different TTCs and lanes. The gr
highway-env/highway_env/envs/common/finite_mdp.py:14
↓ 1 callersFunctionfollow_road
At the end of a lane, automatically switch to a next one.
highway-env/highway_env/envs/common/mdp_controller.py:67
↓ 1 callersFunctionfollow_road
At the end of a lane, automatically switch to a next one.
highway-env/highway_env/envs/common/idm_controller.py:78
↓ 1 callersMethodfull_lateral_lpv_dynamics
State: [position y, yaw psi, lateral speed v, yaw rate r] The system is linearized around psi = 0 :return: lateral dynamics
highway-env/highway_env/vehicle/dynamics.py:171
↓ 1 callersMethodfull_lateral_lpv_structure
State: [position y, yaw psi, lateral speed v, yaw rate r] The system is linearized around psi = 0 :return: lateral dynamics
highway-env/highway_env/vehicle/dynamics.py:150
↓ 1 callersFunctiongenerate_actions
(vehicle, env_copy)
highway-env/highway_env/envs/common/idm_controller.py:59
↓ 1 callersMethodget_color
(cls, vehicle: Vehicle, transparent: bool = False)
highway-env/highway_env/vehicle/graphics.py:144
↓ 1 callersMethodget_color
(cls, object_: 'RoadObject', transparent: bool = False)
highway-env/highway_env/road/graphics.py:338
↓ 1 callersMethodget_followed_lanes
Get the list of lanes that could be followed by this vehicle. :param lane_change_model: - model: assume that the vehicle will follow
highway-env/highway_env/vehicle/uncertainty/prediction.py:300
↓ 1 callersMethodget_image
the rendered image as a rbg array.
highway-env/highway_env/envs/common/graphics.py:136
↓ 1 callersMethodhandle_continuous_action_event
(cls, action_type: ContinuousAction, event: pygame.event.EventType)
highway-env/highway_env/envs/common/graphics.py:178
↓ 1 callersMethodhandle_discrete_action_event
(cls, action_type: DiscreteMetaAction, event: pygame.event.EventType)
highway-env/highway_env/envs/common/graphics.py:166
↓ 1 callersMethodhandle_events
Handle pygame events by forwarding them to the display and environment vehicle.
highway-env/highway_env/envs/common/graphics.py:83
↓ 1 callersMethodheading_at
Get the lane heading at a given longitudinal lane coordinate. :param longitudinal: longitudinal lane coordinate [m] :return:
highway-env/highway_env/road/lane.py:42
↓ 1 callersMethodinteract
(self)
MARL/MADQN.py:84
↓ 1 callersFunctioninterval_local_to_absolute
Converts an interval in local (longiturinal, lateral) coordinates to an interval in absolute x,y coordinates :param longitudinal_i: the long
highway-env/highway_env/interval.py:107
↓ 1 callersMethodis_conflict_possible
(v1: ControlledVehicle, v2: ControlledVehicle, horizon: int = 3, step: float = 0.25)
highway-env/highway_env/road/regulation.py:70
↓ 1 callersMethodis_connected_road
Is the lane 2 leading to a road within lane 1's route? Vehicles on these lanes must be considered for collisions. :param lan
highway-env/highway_env/road/road.py:170
↓ 1 callersFunctionis_consistent_dataset
Check whether a dataset {phi_n, y_n} is consistent The last observation should be in the confidence ellipsoid obtained by the N-1 first obse
highway-env/highway_env/utils.py:189
↓ 1 callersMethodis_leading_to_road
Is lane 1 leading to of lane 2?
highway-env/highway_env/road/road.py:166
↓ 1 callersMethodis_same_road
Is lane 1 in the same road as lane 2?
highway-env/highway_env/road/road.py:161
← previousnext →101–200 of 435, ranked by callers