Skip to content

Latest commit

 

History

History
55 lines (36 loc) · 2.01 KB

README.md

File metadata and controls

55 lines (36 loc) · 2.01 KB

📝 Simple Line Segment Matching


Despite the huge amount of resources about keypoint matching, lesser interest has been shown for line segment matching. Hence, this repository shows some samples related to basic concepts of line segments:

  • Detect line segments using opencv's cv2.ximgproc.createFastLineDetector. The algorithm behind this method is from HERE. This method detects line segments specified by their two end points.
  • Draw line segment's line support region.
  • Extract Line Band Descriptor and match based on the extracted descriptors.

🏃 How to Run


  • Download sample data:
wget https://raw.githubusercontent.com/kailigo/LineMatchingBenchmark/master/benchmark/textureless_corridor/1.png -O ./data/textureless_corridor_1.png
wget https://raw.githubusercontent.com/kailigo/LineMatchingBenchmark/master/benchmark/textureless_corridor/2.png -O ./data/textureless_corridor_2.png
  • Draw detected line segments and their line support regions
python3 scripts/test_line_segment_detection.py --input ./data/textureless_corridor_1.png

detected lines

  • Detect and match line segments (The matching method is quite primitive so the matching accuracy is not high).
python3 scripts/test_line_segment_matching.py --query_path ./data/textureless_corridor_1.png --ref_path ./data/textureless_corridor_2.png

matched lines

🎛 Development environment


mamba env create --file environment.yml
mamba activate lsmh

💎 References