Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ENH] Distance round lap as basis for delta_time #679

Open
psychemedia opened this issue Jan 23, 2025 · 0 comments
Open

[ENH] Distance round lap as basis for delta_time #679

psychemedia opened this issue Jan 23, 2025 · 0 comments

Comments

@psychemedia
Copy link

Proposed new feature or change:

Looking at the utils.delta_time, it appears to be making comparisons based on the distance travelled by each vehicle? Might a better comparison be to model a single racing line trajectory around the circuit, and then map the lat-long co-ords at each point onto that line to calculate a normalised "distance round track" measure?

In shapely, I think this is how you can project a point onto a route (eg the centreline of the circuit):

def map_point_to_route(point, route):
    return route.geometry.interpolate(route.geometry.project(point))

The distance along the route is then route.geometry.project(end_point) - route.geometry.project(start_point)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant