Skip to content
This repository has been archived by the owner on Nov 21, 2023. It is now read-only.

train with cityscapes #293

Closed
jamestodo opened this issue Mar 16, 2018 · 7 comments
Closed

train with cityscapes #293

jamestodo opened this issue Mar 16, 2018 · 7 comments

Comments

@jamestodo
Copy link

I want to train a model with cityscapes by using the configs/getting_started/tutorial_1gpu_e2e_faster_rcnn_R-50-FPN.yaml.I've changed the
NUM_CLASSES as 9,and the cityscapes dataset in my disk look like the description in the lib/datasets/dataset_catalog.py.

And i converted the cityscapes's annotations format to coco annotations format by the lib/datasets/cityscapes/tools/convert_cityscapes_to_coco.py.

I trained the model by the cmd python tools/train_net.py --cfg ./configs/getting_started/tutorial_1gpu_e2e_faster_rcnn_R-50-FPN.yaml

After about 4 hours,the model trained done.And i got the output:
INFO test_engine.py: 212: Wrote detections to: /home/todo/Detectron/output/test/cityscapes_fine_instanceonly_seg_test/generalized_rcnn/detections.pkl INFO test_engine.py: 64: Total inference time: 172.142s INFO task_evaluation.py: 75: Evaluating detections WARNING task_evaluation.py: 83: Cityscapes bbox evaluated using COCO metrics/conversions INFO json_dataset_evaluator.py: 162: Writing bbox results json to: /home/todo/Detectron/output/test/cityscapes_fine_instanceonly_seg_test/generalized_rcnn/bbox_cityscapes_fine_instanceonly_seg_test_results.json INFO task_evaluation.py: 61: Evaluating bounding boxes is done! INFO task_evaluation.py: 180: copypaste: Dataset: cityscapes_fine_instanceonly_seg_test INFO task_evaluation.py: 182: copypaste: Task: box INFO task_evaluation.py: 185: copypaste: AP,AP50,AP75,APs,APm,APl INFO task_evaluation.py: 186: copypaste: -1.0000,-1.0000,-1.0000,-1.0000,-1.0000,-1.0000

The AP all equal to -1.0.Then i run the test demo.Here is the result:

33823288584_1d21cf0a26_k_res

I think it might something error that i didn't know and any suggestion is appreciated.
Thanks a lot!

@wuqi930907
Copy link

Can you tell me how to use 'lib/datasets/cityscapes/tools/convert_cityscapes_to_coco.py' to convert cityscape to coco format?
Thanks @jamestodo

@jamestodo
Copy link
Author

FYI,according to the #111 .

@krumo
Copy link

krumo commented Jun 18, 2018

Hi, did you solve this problem? I got the similar error. @jamestodo

Update:
I think the problem is because I was trying to compute AP on cityscapes_fine_instanceonly_seg_test dataset. Because Detectron will not do evaluation on any dataset whose name contains 'test', Detectron will return a default -1 for all AP. It will be fine if you evaluate on cityscapes validation dataset.

@na-hri
Copy link

na-hri commented Jun 28, 2018

Hi @jamestodo...were you able to solve your issue?

@lssily
Copy link

lssily commented Aug 1, 2018

Hi! Where did you get the convert_cityscapes_to_coco.py?

@cy94
Copy link

cy94 commented Aug 8, 2018

@lssily It's here in case you are still interested

@ir413
Copy link
Contributor

ir413 commented Aug 17, 2018

Closing as the issue seems resolved (see @krumo's updated comment above).

@ir413 ir413 closed this as completed Aug 17, 2018
facebook-github-bot pushed a commit that referenced this issue Sep 3, 2018
Summary:
Fix for #620 & #293.
Pull Request resolved: #624

Reviewed By: ir413

Differential Revision: D9574052

Pulled By: rbgirshick

fbshipit-source-id: f44cea71e5cf6e613d319322db62a60ecb814a75
xzhewei pushed a commit to xzhewei/Detectron that referenced this issue Jan 10, 2019
Summary:
Fix for facebookresearch#620 & facebookresearch#293.
Pull Request resolved: facebookresearch#624

Reviewed By: ir413

Differential Revision: D9574052

Pulled By: rbgirshick

fbshipit-source-id: f44cea71e5cf6e613d319322db62a60ecb814a75
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants