From 5d6927a7d9be841a759b6f5aa8a6d64ae535b552 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ern=C5=91=20Horv=C3=A1th?= Date: Fri, 31 May 2019 16:56:36 +0200 Subject: [PATCH] Remove unused variables and imports --- Mapping/lidar_to_grid_map/lidar_to_grid_map.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/Mapping/lidar_to_grid_map/lidar_to_grid_map.py b/Mapping/lidar_to_grid_map/lidar_to_grid_map.py index cbe50e97..1e390ffe 100644 --- a/Mapping/lidar_to_grid_map/lidar_to_grid_map.py +++ b/Mapping/lidar_to_grid_map/lidar_to_grid_map.py @@ -10,7 +10,6 @@ import math import numpy as np import cv2 import matplotlib.pyplot as plt -from math import cos, sin, radians, pi EXTEND_AREA = 1.0 @@ -103,9 +102,7 @@ def generate_ray_casting_grid_map(ox, oy, xyreso, yawreso, breshen = True): # occupancy grid computed with bresenham ray casting if breshen: for (x, y) in zip(ox, oy): - d = math.sqrt(x**2 + y**2) angle = atan_zero_to_twopi(y, x) - angleid = int(math.floor(angle / yawreso)) ix = int(round((x - minx) / xyreso)) # x coordinte of the the occupied area iy = int(round((y - miny) / xyreso)) # y coordinte of the the occupied area laser_beams = bresenham((centix, centiy), (ix, iy)) # line form the lidar to the cooupied point