Compute haversine distance in meters between track positions for a given track
import numpy as np import aisdb y1, x1 = -66.84683, 44.96421 y2, x2 = -66.83036, 44.9679 y3, x3 = -66.81388, 44.9716 # creating a sample track tracks_short = [ dict( lon=np.array([x1,x2,x3]), lat=np.array([y1,y2,y3]), time=[0,1,2], dynamic=set(['time']), ) ] trk_1 = tracks_short[0] rt_ = aisdb.gis.delta_meters(trk_1)
Last updated 3 months ago