Open daniel-j-h opened 6 years ago
Hi @daniel-j-h, Nvidia's blog states that they use flood fill on SpaceNet Road Detection, I explored it for a day and try to see how it would work on Segmentation training dataset prep. I wasn't able to work it out, and would love to know how you approach it. Keep me updated on your progress, please.
At the moment we generate the segmentation masks based on OpenStreetMap geometries in
rs rasterize
. There is no standard of how fine or coarse geometries are mapped in OpenStreetMap. Sometimes we get fine-detailed masks, sometimes they can be very coarse.See the following for quite a good mask:
We should check if the cv2.floodFill algorithm can help us automatically refining the masks.
It works as follows: start out with a seed pixel in the image and from there grow a region as long as the neighboring pixels are "similar" by color. We probably need to experiment with different color spaces, e.g. converting RGB into HSV and then maybe only using the H channel? The problem I'm seeing here is huge color differences: think cars of different colors, lane marking, parking lot concrete. Needs experimentation.
Tasks:
Note: this does not depend on parking lots. The same applies e.g. for buildings, roads, etc.