本文介绍了osrm路由和匹配服务之间的区别的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

推荐答案

根据 OSRM文档,路由和匹配是具有不同目标的2个端点:

According to OSRM documentation, route and match are 2 endpoints with different objectives:

  • 路线:它将返回提供的订单中协调的路线之间的最快路线.例如:

  • Route: It will return the fastest route between the coordinated in the supplied order. For example:

https://router.project-osrm.org/route/v1/driving/-77.0969009399414,38.89397221118197;-77.08866119384766,38.88154580068335;-77.0745849609375,38.88515369217454;-77.05432891845703,38.90586211685612?overview=false&alternatives=true&steps=true

对此端点的调用将返回从lat: -77.0969009399414, lon: 38.89397221118197lat -77.08866119384766, lon: 38.88154580068335然后到lat: -77.05432891845703, lon: 38.90586211685612

A call to this endpoint will return the shortest path from lat: -77.0969009399414, lon: 38.89397221118197 to lat -77.08866119384766, lon: 38.88154580068335 and then to lat: -77.05432891845703, lon: 38.90586211685612

匹配:此端点适用于完全不同的方式.给定一个GPS数据集,匹配服务将尝试以最可行的方式将这些点与道路网络进行匹配.

Match: This endpoint works in a complete different way. Given a GPS dataset, the match service will try to match those points to the road network in the most pausible way.

因此,如果您有几个GPS点,并且想获得最佳路线来访问它们,则将使用 route 服务.如果您有很多 GPS点,并且想重建最可能的跟踪路径,则可以使用 match 服务

So, if you have few GPS points and want to get the best route to visit them, you will use the route service. If you have a lot of GPS points and want to re-construct the most probable followed path, you will use the match service

这篇关于osrm路由和匹配服务之间的区别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-12 18:54