Skip to content

Instantly share code, notes, and snippets.

View sarahnator's full-sized avatar
🎨

Sarah Etter sarahnator

🎨
View GitHub Profile
@joao-aguizo
joao-aguizo / mbf_costmap_nav.yaml
Created March 17, 2022 15:12
Move Base Flex mbf_costmap_nav template configuration.
#########################
### Static Parameters ###
#########################
robot_frame: base_link # the frame of the robot, which will be used to determine its position
map_frame: map # the global frame the robot is controlling in
force_stop_at_goal: false # force move base flex to stop the robot once the goal is reached
force_stop_on_cancel: false # force move base flex to stop the robot on navigation cancellation
mbf_tolerance_check: false # force move base flex to check for the goal tolerance
dist_tolerance: 0.1 # distance tolerance to the given goal pose
angle_tolerance: 0.175 # angle tolerance to the given goal pose
@Ajk4
Ajk4 / point_cloud_to_depth_map.py
Last active January 26, 2024 12:25
Convert point cloud to depth map
import numpy as np
def pointcloud_to_depth_map(pointcloud: np.ndarray, theta_res=150, phi_res=32, max_depth=50, phi_min_degrees=60,
phi_max_degrees=100) -> np.ndarray:
"""
All params are set so they match default carla lidar settings
"""
assert pointcloud.shape[1] == 3, 'Must have (N, 3) shape'
assert len(pointcloud.shape) == 2, 'Must have (N, 3) shape'