Python sample codes and textbook for robotics algorithms.
215 matches across 8 categories. Click a row to expand file-level details.
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | Mapping/gaussian_grid_map/gaussian_grid_map.py | 19 | def generate_gaussian_grid_map(ox, oy, xyreso, std): |
| LOW | Mapping/lidar_to_grid_map/lidar_to_grid_map.py | 161 | def generate_ray_casting_grid_map(ox, oy, xy_resolution, breshen=True): |
| LOW | Mapping/ndt_map/ndt_map.py | 83 | def create_dummy_observation_data(): |
| LOW | Mapping/ray_casting_grid_map/ray_casting_grid_map.py | 78 | def generate_ray_casting_grid_map(ox, oy, xyreso, yawreso): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 158 | def calc_grid_index_from_xy_index(self, x_ind, y_ind): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 162 | def calc_xy_index_from_grid_index(self, grid_ind): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 166 | def calc_grid_index_from_xy_pos(self, x_pos, y_pos): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 179 | def calc_grid_central_xy_position_from_grid_index(self, grid_ind): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 183 | def calc_grid_central_xy_position_from_xy_index(self, x_ind, y_ind): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 191 | def calc_grid_central_xy_position_from_index(self, index, lower_pos): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 194 | def calc_xy_index_from_position(self, pos, lower_pos, max_index): |
| LOW | Mapping/grid_map_lib/grid_map_lib.py | 201 | def check_occupied_from_xy_index(self, x_ind, y_ind, occupied_val): |
| LOW | …g/normal_vector_estimation/normal_vector_estimation.py | 66 | def ransac_normal_vector_estimation(points_3d, inlier_radio_th=0.7, |
| LOW | Mapping/rectangle_fitting/rectangle_fitting.py | 92 | def _calc_closeness_criterion(self, c1, c2): |
| LOW | Mapping/rectangle_fitting/rectangle_fitting.py | 173 | def _adoptive_range_segmentation(self, ox, oy): |
| LOW | SLAM/GraphBasedSLAM/graphslam/util.py | 34 | def solve_for_edge_dimensionality(n): |
| LOW | SLAM/GraphBasedSLAM/graphslam/util.py | 54 | def upper_triangular_matrix_to_full_matrix(arr, n): |
| LOW | SLAM/ICPMatching/icp_matching.py | 75 | def update_homogeneous_matrix(Hin, R, T): |
| LOW | SLAM/ICPMatching/icp_matching.py | 90 | def nearest_neighbor_association(previous_points, current_points): |
| LOW | SLAM/EKFSLAM/ekf_slam.py | 136 | def get_landmark_position_from_state(x, ind): |
| LOW | SLAM/EKFSLAM/ekf_slam.py | 142 | def search_correspond_landmark_id(xAug, PAug, zi): |
| LOW | PathTracking/pure_pursuit/pure_pursuit.py | 129 | def pure_pursuit_steer_control(state, trajectory, pind): |
| LOW | …ing/lqr_speed_steer_control/lqr_speed_steer_control.py | 96 | def lqr_speed_steering_control(state, cx, cy, cyaw, ck, pe, pth_e, sp, Q, R): |
| LOW | PathTracking/cgmres_nmpc/cgmres_nmpc.py | 66 | def calc_predict_and_adjoint_state(self, x, y, yaw, v, u_1s, u_2s, N, dt): |
| LOW | PathTracking/cgmres_nmpc/cgmres_nmpc.py | 111 | def _predict_state_with_oylar(x, y, yaw, v, u_1, u_2, dt): |
| LOW | PathTracking/cgmres_nmpc/cgmres_nmpc.py | 124 | def _adjoint_state_with_oylar(yaw, v, lam_1, lam_2, lam_3, lam_4, u_2, dt): |
| LOW | …er_control/model_predictive_speed_and_steer_control.py | 223 | def iterative_linear_mpc_control(xref, x0, dref, oa, od): |
| LOW | …_wheel_feedback_control/rear_wheel_feedback_control.py | 105 | def rear_wheel_feedback_control(state, e, k, yaw_ref): |
| LOW | tests/test_dubins_path_planning.py | 72 | def test_path_plannings_types(): |
| LOW | tests/test_rrt_star.py | 22 | def test_no_obstacle_and_robot_radius(): |
| LOW | tests/test_frenet_optimal_trajectory.py | 15 | def high_speed_and_merging_and_stopping_scenario_test(): |
| LOW | tests/test_frenet_optimal_trajectory.py | 23 | def high_speed_and_velocity_keeping_scenario_test(): |
| LOW | tests/test_frenet_optimal_trajectory.py | 31 | def low_speed_and_velocity_keeping_scenario_test(): |
| LOW | tests/test_frenet_optimal_trajectory.py | 39 | def low_speed_and_merging_and_stopping_scenario_test(): |
| LOW | tests/test_distance_map.py | 89 | def test_compute_udf_invalid_input(): |
| LOW | tests/test_grid_map_lib.py | 28 | def test_xy_and_grid_index_conversion(): |
| LOW | tests/test_rrt_with_pathsmoothing_radius.py | 6 | def test_smoothed_path_safety(): |
| LOW | docs/conf.py | 223 | def get_relative_path_from_parent(file_path: str, parent_dir: str): |
| LOW | InvertedPendulum/inverted_pendulum_lqr_control.py | 116 | def get_numpy_array_from_matrix(x): |
| LOW | InvertedPendulum/inverted_pendulum_mpc_control.py | 111 | def get_numpy_array_from_matrix(x): |
| LOW | MissionPlanning/StateMachine/robot_behavior_case.py | 88 | def on_enter_returning_to_base(self): |
| LOW | MissionPlanning/BehaviorTree/behavior_tree.py | 82 | def not_set_children_raise_error(self): |
| LOW | MissionPlanning/BehaviorTree/behavior_tree.py | 303 | def not_set_child_raise_error(self): |
| LOW | MissionPlanning/BehaviorTree/robot_behavior_case.py | 169 | def create_robot_behavior_tree(): |
| LOW | …thPlanning/ReedsSheppPath/reeds_shepp_path_planning.py | 177 | def left_x_right_left_x_right(x, y, phi): |
| LOW | …thPlanning/ReedsSheppPath/reeds_shepp_path_planning.py | 345 | def calc_interpolate_dists_list(lengths, step_size): |
| LOW | …thPlanning/ReedsSheppPath/reeds_shepp_path_planning.py | 427 | def reeds_shepp_path_planning(sx, sy, syaw, gx, gy, gyaw, maxc, step_size=0.2): |
| LOW | …redictiveTrajectoryGenerator/lookup_table_generator.py | 37 | def search_nearest_one_from_lookup_table(tx, ty, tyaw, lookup_table): |
| LOW | PathPlanning/BSplinePath/bspline_path.py | 19 | def approximate_b_spline_path(x: list, |
| LOW | PathPlanning/BSplinePath/bspline_path.py | 66 | def interpolate_b_spline_path(x, y, |
| LOW | PathPlanning/HybridAStar/hybrid_a_star.py | 182 | def update_node_with_analytic_expansion(current, goal, |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 129 | def calc_cartesian_parameters(self, fp, csp): |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 175 | def calc_cartesian_parameters(self, fp, csp): |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 217 | def calc_cartesian_parameters(self, fp, csp): |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 241 | def calc_longitudinal_trajectory(self, c_speed, c_accel, Ti, s0): |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 261 | def calc_longitudinal_trajectory(self, c_speed, c_accel, Ti, s0): |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 285 | def calc_longitudinal_trajectory(self, c_speed, c_accel, Ti, s0): |
| LOW | PathPlanning/VisibilityRoadMap/visibility_road_map.py | 49 | def generate_visibility_nodes(self, start_x, start_y, goal_x, goal_y, |
| LOW | PathPlanning/VisibilityRoadMap/visibility_road_map.py | 71 | def calc_vertexes_in_configuration_space(self, x_list, y_list): |
| LOW | …ning/TimeBasedPathPlanning/GridWithDynamicObstacles.py | 82 | def generate_dynamic_obstacles(self, obs_count: int) -> list[list[Position]]: |
| 31 more matches not shown… | |||
| Severity | File | Line | Snippet |
|---|---|---|---|
| HIGH | …ing/lqr_speed_steer_control/lqr_speed_steer_control.py | 0 | solve a discrete time_algebraic riccati equation (dare) |
| HIGH | PathTracking/lqr_steer_control/lqr_steer_control.py | 0 | solve a discrete time_algebraic riccati equation (dare) |
| HIGH | InvertedPendulum/inverted_pendulum_lqr_control.py | 0 | solve a discrete time_algebraic riccati equation (dare) |
| HIGH | PathPlanning/LQRPlanner/lqr_planner.py | 0 | solve a discrete time_algebraic riccati equation (dare) |
| HIGH | …ing/lqr_speed_steer_control/lqr_speed_steer_control.py | 0 | solve the discrete time lqr controller. x[k+1] = a x[k] + b u[k] cost = sum x[k].t*q*x[k] + u[k].t*r*u[k] # ref bertseka |
| HIGH | PathTracking/lqr_steer_control/lqr_steer_control.py | 0 | solve the discrete time lqr controller. x[k+1] = a x[k] + b u[k] cost = sum x[k].t*q*x[k] + u[k].t*r*u[k] # ref bertseka |
| HIGH | InvertedPendulum/inverted_pendulum_lqr_control.py | 0 | solve the discrete time lqr controller. x[k+1] = a x[k] + b u[k] cost = sum x[k].t*q*x[k] + u[k].t*r*u[k] # ref bertseka |
| HIGH | PathPlanning/LQRPlanner/lqr_planner.py | 0 | solve the discrete time lqr controller. x[k+1] = a x[k] + b u[k] cost = sum x[k].t*q*x[k] + u[k].t*r*u[k] # ref bertseka |
| HIGH | PathPlanning/AStar/a_star.py | 0 | calc grid position :param index: :param min_position: :return: |
| HIGH | …eadthFirstSearch/bidirectional_breadth_first_search.py | 0 | calc grid position :param index: :param min_position: :return: |
| HIGH | PathPlanning/BidirectionalAStar/bidirectional_a_star.py | 0 | calc grid position :param index: :param min_position: :return: |
| HIGH | PathPlanning/ThetaStar/theta_star.py | 0 | calc grid position :param index: :param min_position: :return: |
| HIGH | PathPlanning/BreadthFirstSearch/breadth_first_search.py | 0 | calc grid position :param index: :param minp: :return: |
| HIGH | PathPlanning/DepthFirstSearch/depth_first_search.py | 0 | calc grid position :param index: :param minp: :return: |
| HIGH | …ning/GreedyBestFirstSearch/greedy_best_first_search.py | 0 | calc grid position :param index: :param minp: :return: |
| HIGH | PathPlanning/LQRRRTStar/lqr_rrt_star.py | 0 | setting parameter start:start position [x,y] goal:goal position [x,y] obstaclelist:obstacle positions [[x,y,size],...] r |
| HIGH | PathPlanning/RRTDubins/rrt_dubins.py | 0 | setting parameter start:start position [x,y] goal:goal position [x,y] obstaclelist:obstacle positions [[x,y,size],...] r |
| HIGH | PathPlanning/RRTStarReedsShepp/rrt_star_reeds_shepp.py | 0 | setting parameter start:start position [x,y] goal:goal position [x,y] obstaclelist:obstacle positions [[x,y,size],...] r |
| HIGH | PathPlanning/RRTStarDubins/rrt_star_dubins.py | 0 | setting parameter start:start position [x,y] goal:goal position [x,y] obstaclelist:obstacle positions [[x,y,size],...] r |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | Mapping/gaussian_grid_map/gaussian_grid_map.py | 19 | |
| LOW | Mapping/rectangle_fitting/rectangle_fitting.py | 233 | |
| LOW | Mapping/rectangle_fitting/rectangle_fitting.py | 126 | |
| LOW | SLAM/GraphBasedSLAM/graph_based_slam.py | 105 | |
| LOW | PathTracking/pure_pursuit/pure_pursuit.py | 269 | |
| LOW | MissionPlanning/BehaviorTree/behavior_tree.py | 196 | |
| LOW | MissionPlanning/BehaviorTree/behavior_tree.py | 613 | |
| LOW | …thPlanning/ReedsSheppPath/reeds_shepp_path_planning.py | 287 | |
| LOW | PathPlanning/AStar/a_star_variants.py | 56 | |
| LOW | PathPlanning/AStar/a_star_variants.py | 180 | |
| LOW | PathPlanning/AStar/a_star_variants.py | 267 | |
| LOW | PathPlanning/AStar/a_star.py | 51 | |
| LOW | PathPlanning/AStar/a_star.py | 170 | |
| LOW | PathPlanning/AStar/a_star.py | 189 | |
| LOW | PathPlanning/AStar/a_star_searching_from_two_side.py | 131 | |
| LOW | …hPlanning/HybridAStar/dynamic_programming_heuristic.py | 45 | |
| LOW | …hPlanning/HybridAStar/dynamic_programming_heuristic.py | 120 | |
| LOW | …hPlanning/HybridAStar/dynamic_programming_heuristic.py | 136 | |
| LOW | PathPlanning/FlowField/flowfield.py | 46 | |
| LOW | PathPlanning/FlowField/flowfield.py | 63 | |
| LOW | …g/FrenetOptimalTrajectory/frenet_optimal_trajectory.py | 450 | |
| LOW | PathPlanning/BreadthFirstSearch/breadth_first_search.py | 146 | |
| LOW | PathPlanning/BreadthFirstSearch/breadth_first_search.py | 165 | |
| LOW | …eadthFirstSearch/bidirectional_breadth_first_search.py | 204 | |
| LOW | …eadthFirstSearch/bidirectional_breadth_first_search.py | 223 | |
| LOW | PathPlanning/DStar/dstar.py | 93 | |
| LOW | PathPlanning/VoronoiRoadMap/dijkstra_search.py | 34 | |
| LOW | PathPlanning/DepthFirstSearch/depth_first_search.py | 143 | |
| LOW | PathPlanning/DepthFirstSearch/depth_first_search.py | 162 | |
| LOW | PathPlanning/VisibilityRoadMap/visibility_road_map.py | 89 | |
| LOW | …lanning/Eta3SplineTrajectory/eta3_spline_trajectory.py | 199 | |
| LOW | PathPlanning/TimeBasedPathPlanning/Plotting.py | 53 | |
| LOW | PathPlanning/TimeBasedPathPlanning/SpaceTimeAStar.py | 27 | |
| LOW | …ning/TimeBasedPathPlanning/GridWithDynamicObstacles.py | 82 | |
| LOW | PathPlanning/TimeBasedPathPlanning/SafeInterval.py | 50 | |
| LOW | PathPlanning/TimeBasedPathPlanning/SafeInterval.py | 102 | |
| LOW | PathPlanning/InformedRRTStar/informed_rrt_star.py | 44 | |
| LOW | PathPlanning/BidirectionalAStar/bidirectional_a_star.py | 49 | |
| LOW | PathPlanning/BidirectionalAStar/bidirectional_a_star.py | 235 | |
| LOW | PathPlanning/BidirectionalAStar/bidirectional_a_star.py | 254 | |
| LOW | …anning/WavefrontCPP/wavefront_coverage_path_planner.py | 20 | |
| LOW | …anning/WavefrontCPP/wavefront_coverage_path_planner.py | 94 | |
| LOW | …anning/WavefrontCPP/wavefront_coverage_path_planner.py | 113 | |
| LOW | PathPlanning/ElasticBands/elastic_bands.py | 257 | |
| LOW | PathPlanning/RRT/sobol/sobol.py | 218 | |
| LOW | PathPlanning/ThetaStar/theta_star.py | 51 | |
| LOW | PathPlanning/ThetaStar/theta_star.py | 233 | |
| LOW | PathPlanning/ThetaStar/theta_star.py | 252 | |
| LOW | …gTreeCPP/spiral_spanning_tree_coverage_path_planner.py | 36 | |
| LOW | …gTreeCPP/spiral_spanning_tree_coverage_path_planner.py | 73 | |
| LOW | …gTreeCPP/spiral_spanning_tree_coverage_path_planner.py | 132 | |
| LOW | …gTreeCPP/spiral_spanning_tree_coverage_path_planner.py | 154 | |
| LOW | …gTreeCPP/spiral_spanning_tree_coverage_path_planner.py | 171 | |
| LOW | …gTreeCPP/spiral_spanning_tree_coverage_path_planner.py | 187 | |
| LOW | PathPlanning/BugPlanning/bug.py | 14 | |
| LOW | PathPlanning/BugPlanning/bug.py | 39 | |
| LOW | PathPlanning/BugPlanning/bug.py | 55 | |
| LOW | PathPlanning/BugPlanning/bug.py | 116 | |
| LOW | PathPlanning/BugPlanning/bug.py | 193 | |
| LOW | …anning/BatchInformedRRTStar/batch_informed_rrt_star.py | 233 | |
| 17 more matches not shown… | |||
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | PathTracking/pure_pursuit/pure_pursuit.py | 323 | if not plt.get_fignums(): # Check if window is closed |
| LOW | tests/test_rrt_with_pathsmoothing_radius.py | 38 | # Check if all points on the smoothed path are safely distant from obstacles |
| LOW | tests/test_move_to_pose.py | 33 | # Check if the speed is changing too much |
| LOW | PathPlanning/TimeBasedPathPlanning/SpaceTimeAStar.py | 96 | # Check if the new node is valid for the next 2 time steps - one step to enter, and another to leave |
| LOW | …ning/TimeBasedPathPlanning/GridWithDynamicObstacles.py | 199 | # Check if position is in grid |
| LOW | …ning/TimeBasedPathPlanning/GridWithDynamicObstacles.py | 203 | # Check if position is not occupied at time t |
| LOW | …rticleSwarmOptimization/particle_swarm_optimization.py | 132 | # Check if start point is inside obstacle |
| LOW | …rticleSwarmOptimization/particle_swarm_optimization.py | 139 | # Check if intersection on segment |
| LOW | …anning/BatchInformedRRTStar/batch_informed_rrt_star.py | 254 | # Check if this can improve the current solution |
| LOW | …anning/BatchInformedRRTStar/batch_informed_rrt_star.py | 534 | # Check if we're at the goal |
| Severity | File | Line | Snippet |
|---|---|---|---|
| MEDIUM | …er_control/model_predictive_speed_and_steer_control.py | 297 | print("Error: Cannot solve mpc..") |
| LOW | docs/conf.py | 217 | except Exception: |
| LOW | MissionPlanning/StateMachine/state_machine.py | 291 | except Exception as e: |
| MEDIUM | MissionPlanning/StateMachine/state_machine.py | 292 | print(f"Error showing PlantUML: {e}") |
| MEDIUM | PathPlanning/HybridAStar/hybrid_a_star.py | 284 | print("Error: Cannot find path, No open set") |
| LOW | PathPlanning/ClothoidPath/clothoid_path_planner.py | 76 | except Exception as e: |
| LOW | PathPlanning/ClothoidPath/clothoid_path_planner.py | 89 | except Exception as e: |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | SLAM/GraphBasedSLAM/graphslam/edge/__init__.py | 1 | # Copyright (c) 2020 Jeff Irion and contributors |
| LOW | SLAM/GraphBasedSLAM/graphslam/pose/__init__.py | 1 | # Copyright (c) 2020 Jeff Irion and contributors |
| LOW | PathTracking/move_to_pose/move_to_pose.py | 61 | v : Command linear velocity |
| LOW | docs/conf.py | 1 | # |
| LOW | docs/conf.py | 121 | # Custom sidebar templates, must be a dictionary that maps document names |
| LOW | docs/conf.py | 141 | # The paper size ('letterpaper' or 'a4paper'). |
| LOW | PathPlanning/DStarLite/d_star_lite.py | 381 | # Obstacles discovered at time = row |
| Severity | File | Line | Snippet |
|---|---|---|---|
| MEDIUM | tests/test_distance_map.py | 8 | # Create a simple obstacle map for testing |
| MEDIUM | PathPlanning/ElasticBands/elastic_bands.py | 289 | # Create an elastic band object and optimize |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | SLAM/ICPMatching/icp_matching.py | 8 | |
| LOW | PathPlanning/RRT/sobol/__init__.py | 1 |