hasanirtiza / Pedestron

[Pedestron] Generalizable Pedestrian Detection: The Elephant In The Room. @ CVPR2021
https://openaccess.thecvf.com/content/CVPR2021/papers/Hasan_Generalizable_Pedestrian_Detection_The_Elephant_in_the_Room_CVPR_2021_paper.pdf
Apache License 2.0
690 stars 158 forks source link

test_euroCity.py no --out argument in def parse_args(): #26

Closed ShaneGilroy closed 4 years ago

ShaneGilroy commented 4 years ago

Hi,

This may have been intentional however the "def parse_args():" Function in "test_euroCity.py" appears to be missing "parser.add_argument('--out', help='output result file')"

I am trying to test Eurocity Persons dataset with something similar to below however "--out" is displaying the following error:

"test_euroCity.py: error: unrecognized arguments: --out"

Can you provide the correct argument to test the Eurocity dataset using a single GPU? I am using this at the moment but not with the test_euroCity.py

./tools/dist_test.sh configs/elephant/eurocity/cascade_hrnet.py ./models_pretrained/epoch_147.pth.stu 1 --out euroCity.pkl --eval bbox

hasanirtiza commented 4 years ago

Hi, The issue is that the evaluation of EuroCity Person is slightly different from say CityPersons. We had to tailor it to the official evaluation protocol. Therefore, the test_euroCity.py takes no argument --out. Instead, if you look at test_euroCity.py (70-71 lines) , you can see that it basically creates a mock_detection folder and writes all detections over there. This choice is dictated by the evaluation protocol of ECP dataset and if you want to make a submission to ECP servers, thats how they accept it.

So in a nutshell, for EuroCity Persons you should run the following command for a single gpu test

python ./tools/test_euroCity.py configs/elephant/eurocity/cascade_hrnet.py ./models_pretrained/epoch_ 147 148 --mean_teacher
ShaneGilroy commented 4 years ago

Excellent reply, thanks.

hasanirtiza commented 4 years ago

By the way, there was a small path issue in : ./tools/ECPB/eval.py. Now it is resolved, just in case you ran into it.

ShaneGilroy commented 4 years ago

Got that, thanks.