Skip to content
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

error during testing with preparing segm results RuntimeError: sizes do not match #99

Closed
jpainam opened this issue Aug 20, 2020 · 0 comments

Comments

@jpainam
Copy link

jpainam commented Aug 20, 2020

Hi, during testing, with this command
python tools/test_net.py --config-file "configs/e2e_mask_rcnn_R_50_FPN_1x.yaml"
i get this error

2020-08-20 22:05:04,655 maskrcnn_benchmark.inference INFO: Preparing results for COCO format
2020-08-20 22:05:04,656 maskrcnn_benchmark.inference INFO: Preparing bbox results
2020-08-20 22:05:04,866 maskrcnn_benchmark.inference INFO: Preparing segm results
19it [00:10,  1.65it/s]Traceback (most recent call last):
  File "tools/test_net.py", line 94, in <module>
    main()
  File "tools/test_net.py", line 88, in main
    maskiou_on=cfg.MODEL.MASKIOU_ON
  File "/home/eldad/maskscoring_rcnn/maskrcnn_benchmark/engine/inference.py", line 420, in inference
    coco_results["segm"] = prepare_for_coco_segmentation(predictions, dataset, maskiou_on)
  File "/home/eldad/maskscoring_rcnn/maskrcnn_benchmark/engine/inference.py", line 94, in prepare_for_coco_segmentation
    masks = masker(masks.expand(1, -1, -1, -1, -1), prediction)
  File "/home/eldad/maskscoring_rcnn/maskrcnn_benchmark/modeling/roi_heads/mask_head/inference.py", line 192, in __call__
    result = self.forward_single_image(mask, box)
  File "/home/eldad/maskscoring_rcnn/maskrcnn_benchmark/modeling/roi_heads/mask_head/inference.py", line 172, in forward_single_image
    for mask, box in zip(masks, boxes.bbox)
  File "/home/eldad/maskscoring_rcnn/maskrcnn_benchmark/modeling/roi_heads/mask_head/inference.py", line 172, in <listcomp>
    for mask, box in zip(masks, boxes.bbox)
  File "/home/eldad/maskscoring_rcnn/maskrcnn_benchmark/modeling/roi_heads/mask_head/inference.py", line 152, in paste_mask_in_image
    (y_0 - box[1]) : (y_1 - box[1]), (x_0 - box[0]) : (x_1 - box[0])
RuntimeError: sizes do not match

anything wrong?
thanks for helping

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant