hotfix

-nearest depth value instead of median
-group lines with a threshold