aboutsummaryrefslogtreecommitdiffhomepage
path: root/scripts
diff options
context:
space:
mode:
authortypebrook <typebrook@gmail.com>2019-12-04 17:54:26 +0800
committertypebrook <typebrook@gmail.com>2019-12-05 09:33:11 +0800
commit3007916bea51530b2b604f6ceffbbea81e4a01e9 (patch)
treed4f750351618295ce188f0ed2127ad208143eff8 /scripts
parentba040a3614f2786bc8c4ff951e5663eee871174a (diff)
update
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/match-road.sh1
1 files changed, 1 insertions, 0 deletions
diff --git a/scripts/match-road.sh b/scripts/match-road.sh
index 68d7c8a..b3f48d2 100755
--- a/scripts/match-road.sh
+++ b/scripts/match-road.sh
@@ -38,6 +38,7 @@ while [ -s $ORIGIN_DATA ]; do
38 jq --slurp '{type: "Feature", properties: {coordTimes: .[1]}, geometry: {type: "LineString", coordinates: .[0]}}' \ 38 jq --slurp '{type: "Feature", properties: {coordTimes: .[1]}, geometry: {type: "LineString", coordinates: .[0]}}' \
39 <(head -$LIMIT $ORIGIN_DATA | cut -d' ' -f2 | jq -n '[inputs]') \ 39 <(head -$LIMIT $ORIGIN_DATA | cut -d' ' -f2 | jq -n '[inputs]') \
40 <(head -$LIMIT $ORIGIN_DATA | cut -d' ' -f1 | jq -nR '[inputs]') |\ 40 <(head -$LIMIT $ORIGIN_DATA | cut -d' ' -f1 | jq -nR '[inputs]') |\
41 tee tmp_$(head -1 $ORIGIN_DATA | cut -d ' ' -f1 | date -f - +%s).geojson |\
41 # Mapbox Map Matching API, store response into tmp file 42 # Mapbox Map Matching API, store response into tmp file
42 curl -X POST -s --data @- --header "Content-Type:application/json" https://api.mapbox.com/matching/v4/mapbox.driving.json?access_token=$ACCESS_TOKEN > $RESPONSE 43 curl -X POST -s --data @- --header "Content-Type:application/json" https://api.mapbox.com/matching/v4/mapbox.driving.json?access_token=$ACCESS_TOKEN > $RESPONSE
43 44