HLTP
HLTP copied to clipboard
Preprocessing script for NGSIM data
I'm trying to reproduce your results. ~~Can you please share a script for converting the NGSIM csv/txt data to the MAT format this repo expects?~~ Edit: conversion script exists, see my next comment.
I tried using the files from BATraj NGSIM release but when I run python evaluate_teacher.py
I get the following error:
IndexError: Caught IndexError in DataLoader worker process 0.
Original Traceback (most recent call last):
File "/home/ben/hubrisDev/HLTP/venv/lib/python3.9/site-packages/torch/utils/data/_utils/worker.py", line 302, in _worker_loop
data = fetcher.fetch(index)
File "/home/ben/hubrisDev/HLTP/venv/lib/python3.9/site-packages/torch/utils/data/_utils/fetch.py", line 58, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/ben/hubrisDev/HLTP/venv/lib/python3.9/site-packages/torch/utils/data/_utils/fetch.py", line 58, in <listcomp>
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/ben/hubrisDev/HLTP/loader2.py", line 54, in __getitem__
lane_stu = self.getLane_stu(vehId, t, vehId, dsId)
File "/home/ben/hubrisDev/HLTP/loader2.py", line 205, in getLane_stu
refPos = refTrack[np.where(refTrack[:, 0] == t)][0, 5]
IndexError: index 5 is out of bounds for axis 1 with size 4
I get the same error if I fix the paths and try to run evaluate_teacher.py
.