Problem in measuring the width of obstacles using LiDAR
I'm using a Hokuyo UTM-30LX lidar on a mobile robot to measure the dimensions of obstacles from a distance. Being a 2D LiDAR, i'm starting off trying to measure the width of a door.
Finding the number of LiDAR data points that fall on the door and the angle of resolution of the LiDAR, i'm calculating the approximate width using the range valuesfor the points falling on the door. So far the results haven't been accurate enough.
Is there any work available where in which a LiDAR has been used with ROS to measure the dimention of objects? Could anyone suggest any changes to the method of know what might usually work?
Specs:
OS: Ubuntu 14.04 ROS: Indigo Sensor: Hokuyo UTM-30LX LiDAR.
Thank you.
You could have a look at RANSAC algorithm. It can be used for line detection (which should detect your door), so you could read the first and last points detected to calculate the width of the detected object.