routine to find shortest course completion
If rowing through start box more than 1 time, it checks for every passing of the start box
This commit is contained in:
@@ -33,7 +33,7 @@ from rowers.models import (
|
||||
)
|
||||
|
||||
from utils import geo_distance
|
||||
from rowers.courseutils import coursetime_paths, coursetime_first
|
||||
from rowers.courseutils import coursetime_paths, coursetime_first,time_in_path
|
||||
|
||||
|
||||
|
||||
@@ -199,12 +199,16 @@ def get_time_course(ws,course):
|
||||
rowdata = rowdata.resample('100ms',on='dt').mean()
|
||||
rowdata = rowdata.interpolate()
|
||||
|
||||
# create path
|
||||
polygons = GeoPolygon.objects.filter(course=course).order_by("order_in_course")
|
||||
paths = []
|
||||
for polygon in polygons:
|
||||
path = polygon_to_path(polygon)
|
||||
paths.append(path)
|
||||
|
||||
|
||||
|
||||
|
||||
(
|
||||
coursetimeseconds,
|
||||
coursemeters,
|
||||
|
||||
Reference in New Issue
Block a user