What are the best algorithms to match segments?
I'm trying to match corresponding segments from two map sources, one less accurate but with segment names, and one more accurate without segment names. I want to semi-automatically apply the segment names to the more accurate map.
The requested algorithm has quite a vague description because a "match" is not well defined, and many factors (orientation, relative length, distance) might have different weight in different scenarios; However, I'm looking for a basic knowledge about the general approaches for handling this problem.
WorkingI seek working implementations for an open-source environment (PostGIS, shapely, ...etc) are warmly welcome.
Sample segments : See description below images.