second.pytorch icon indicating copy to clipboard operation
second.pytorch copied to clipboard

Evaluation on Mini dataset gives ""Samples in split doesn't match samples in predictions.""

Open chowkamlee81 opened this issue 5 years ago • 5 comments

For training and val dataset , evaluation toolkit works but when i start evaluating on v1.0 mini dataset gives

""Samples in split doesn't match samples in predictions.""

Kindly help

chowkamlee81 avatar Dec 02 '19 06:12 chowkamlee81

Hi, dude, have you solved this problem, I also encountered this problem, THANKS

tjucwb avatar Feb 14 '20 17:02 tjucwb

I solved that, just modify line 308 in nuscenes_dataset.py eval_set_map, from "v1.0-mini": "mini_train" to "v1.0-mini": "mini_val", additionally, the size of either set, train_scenes and val_scenes can not be zero

tjucwb avatar Feb 14 '20 17:02 tjucwb

See tools/dist_test.py#L201.

This problem occurs because v1.0-trainval dataset is loaded. (not v1.0-mini)

Change

result_dict, _ = dataset.evaluation(copy.deepcopy(predictions), output_dir=args.work_dir, testset=args.testset)

to

dataset.version = "v1.0-mini"
result_dict, _ = dataset.evaluation(copy.deepcopy(predictions), output_dir=args.work_dir, testset=args.testset)

This command causes dataset.version to change from v1.0-trainval to v1.0-mini.

3846chs avatar Sep 27 '22 05:09 3846chs

I used "v1.0-mini“ and meet this problem. I modify this line : eval_set_map = { 'v1.0-mini': 'mini_val', 'v1.0-trainval': 'val', } to : eval_set_map = { 'v1.0-mini': 'mini_train', 'v1.0-trainval': 'val', }

wongyibin avatar Jan 16 '23 10:01 wongyibin

hmm still happens to me even though it already says: "v1.0-mini": "mini_val"

Byte247 avatar Jan 30 '24 13:01 Byte247