-
Notifications
You must be signed in to change notification settings - Fork 14
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
When I used the weight file I trained to evaluate, I encountered the following error, how can I solve it? #3
Comments
I have the same error when trying to evaluate after training, the contents of
|
Sorry for the delayed response, please try out the following command for evaluation: python pytorch/train.py evaluate --config_path=configs/pointpillars/car/xyres_16.proto --model_dir=trained_model_dir/ --ckpt_path=trained_model_dir/ckpt/voxelnet-324800.tckpt --pickle_result=True --ref_detfile=./rgb_detections/rgb_detection_val.txt For evaluation of the validation or test dataset, we must provide a 2D reference detections file or a directory that contains 2D detections in the KITTI format. (check the function evaluate() in train.py file) For the validation dataset, a reference detection file is already provided. This is the same as the one provided by the F-PointNet codebase. For the test dataset, I have generated 2D detections using Faster R-CNN trained on the EuroCityPersons dataset. I will add those to this repo so that you can evaluate the test set also. |
Hey, thanks for your reply. Unfortunately, I still get the same error when using your suggested command.
I got to run the evaluation by downloading reference 3D object detections from the kitti 3D object detection 2017 website (https://s3.eu-central-1.amazonaws.com/avg-kitti/data_object_det_2.zip) and extracted them to the kitti testing folder
Then I used the evaluate script like so: Then some results were saved in kitti format in the |
Thanks for your reply, but I still show an error based on your prompts: I used the evaluate script like so:
.......... Can you see what went wrong?Thank you so much! |
Try |
Thanks for your help ,but it shows the same error as above |
Ah now I see it. Check my command. You need to pass |
@xuyunf Hello!Did you solve this problem? If yes could you please share the solution to this problem? |
ubuntu@VM-0-11-ubuntu:~/Frustum-Pointpillars/second$ python ./pytorch/train.py evaluate --config_path=./configs/pointpillars/car/xyres_16.proto --model_dir=./model
middle_class_name PointPillarsScatter
Restoring parameters from model/voxelnet-29503.tckpt
remain number of infos: 7518
Generate output labels...
Traceback (most recent call last):
File "./pytorch/train.py", line 771, in
fire.Fire()
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/fire/core.py", line 141, in Fire
component_trace = _Fire(component, args, parsed_flag_args, context, name)
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/fire/core.py", line 471, in _Fire
target=component.name)
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/fire/core.py", line 681, in _CallAndUpdateTrace
component = fn(*varargs, **kwargs)
File "./pytorch/train.py", line 740, in evaluate
for example in iter(eval_dataloader):
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 435, in next
data = self._next_data()
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 1085, in _next_data
return self._process_data(data)
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 1111, in _process_data
data.reraise()
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/_utils.py", line 428, in reraise
raise self.exc_type(msg)
KeyError: Caught KeyError in DataLoader worker process 0.
Original Traceback (most recent call last):
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/utils/data/_utils/worker.py", line 198, in _worker_loop
data = fetcher.fetch(index)
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/ubuntu/anaconda3/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/ubuntu/Frustum-Pointpillars/second/pytorch/builder/input_reader_builder.py", line 42, in getitem
return self._dataset[idx]
File "/home/ubuntu/Frustum-Pointpillars/second/data/dataset.py", line 68, in getitem
prep_func=self._prep_func)
File "/home/ubuntu/Frustum-Pointpillars/second/data/preprocess.py", line 556, in _read_and_prep_v9
example = prep_func(input_dict=input_dict)
File "/home/ubuntu/Frustum-Pointpillars/second/data/preprocess.py", line 143, in prep_pointcloud
ref_bboxes = input_dict["bboxes"]
KeyError: 'bboxes'
The text was updated successfully, but these errors were encountered: