Occupancy Map from Hough Lines
I have written a script that detects boundary lines in a camera frame using Hough Lines in OpenCV. I want to turn these detection into an occupancy grid where the detected lines are boundaries and any space between the lines is free space in which the robot may traverse. Any help or ideas?
Are you creating a full map to be used for global path planning purposes or want to convert a single reading to an occupancy grid for local planning reasons?
Good question. I think the second is fine for my purpose.
Ok. Is this an academic/hobby project? What language are you using?
This is a hobby project. I have written the detection code in python, but am willing to work with C++ as well.
Are you working with a single image? If it's forward-facing camera you don't have distance for any of the lines, so how will you fill in the occupancy map? If you have two stereo images, you'll have to match lines detected in the two images somehow in order to determine the depth. That may be just as hard as using a more standard approach using feature detection, for which there are existing ROS packages.