Closed dfridovi closed 1 month ago
Ok. Maybe the segfaults were an anomaly because I can't reproduce them now. However, the lane change example is waaaay slower than it used to be, so something is fishy. To reproduce:
] activate examples
then
includet("examples/TrajectoryExamples.jl")
TrajectoryExamples.run_lane_change_example()
and I see:
Progress: 100%|█████████████████████████████████████████| Time: 0:01:20
(it used to take ~1 s)
Ok fixed the bug! Was converting from sparse to dense in order to get ldiv!
to work. Found a workaround. Might be worth revisiting this bit here in AutoDiff.jl
@lassepe
Anyway, now the example runs much faster:
julia> TrajectoryExamples.run_lane_change_example()
Progress: 100%|█████████████████████████████████████████| Time: 0:00:03
Employs in-place computation for Jacobians in the solver. There is more optimization that could be done here, but this is a first step.
Addresses #13.