WaterlooRobotics / mobilerobotics

Matlab and Robot code for MTE 544: Autonomous Mobile Robotics at the University of Waterloo
66 stars 38 forks source link

I15 oc mapping #36

Closed icolwell closed 7 years ago

icolwell commented 8 years ago

Summary Everything was moved from "matlab_simulation/code v1.0/ME597-6-Mapping/" to "matlab_simulation/06-mapping/occupancy_grid/" or to the appropriate folder. Some duplicated functions were also removed.

Examples There are 4 examples I included:

%% Occupancy grid mapping example 1 Uses a 50 x 60 cell map with a laser scanner, map is updated using Bresenham ray trace mode.

%% Occupancy grid mapping example 2 Uses a 50 x 60 cell map with a laser scanner, map is updated using windowed block update mode.

%% Occupancy grid mapping example 3 Uses a 50 x 60 cell map with sonar, map is updated using windowed block update mode.

%% Occupancy grid mapping example 4 Performance test on a large map. Uses a 1000 x 1000 cell map with a laser scanner, map is updated using Bresenham ray trace mode. Laser scanner range and FOV increased.

New Functions: -ogmap = Does occupancy grid mapping -get_sonar_range = returns the range of nearest obstacle using sonar -load_cell_map = generates a couple different types of cell maps -inverse_scanner-window = does block update mode but only iterates over the window defined by the max range of the sensor and boundaries of the map. Could likely be optimized further based on FOV and sensor angle but it is a good start. -various plotting functions specific to these mapping examples

UPDATES AFTER CODE REVIEW -Added the map border padding as Stan mentioned to remove an if statement from a loop. -Reviewed all files and made small formatting improvements according to Stan's comment. -Updated inverse_scanner_bres.m to take in the probabilities of occupied and unoccupied cells as arguments. -Clarified a couple comments

icolwell commented 7 years ago

:smile: