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

min() arg is an empty sequence #469

Closed
junxiaoge opened this issue Jun 4, 2018 · 3 comments
Closed

min() arg is an empty sequence #469

junxiaoge opened this issue Jun 4, 2018 · 3 comments

Comments

@junxiaoge
Copy link

E0604 12:01:30.918792 20556 pybind_state.h:422] Exception encountered running PythonOp function: ValueError: min() arg is an empty sequence

At:
/home/server010/disk/Detectron--s/detectron/utils/segms.py(125): polys_to_boxes
/home/server010/disk/Detectron--s/detectron/roi_data/mask_rcnn.py(46): add_mask_rcnn_blobs
/home/server010/disk/Detectron--s/detectron/roi_data/fast_rcnn.py(197): _sample_rois
/home/server010/disk/Detectron--s/detectron/roi_data/fast_rcnn.py(112): add_fast_rcnn_blobs
/home/server010/disk/Detectron--s/detectron/ops/collect_and_distribute_fpn_rpn_proposals.py(62): forward
terminate called after throwing an instance of 'caffe2::EnforceNotMet'
what(): [enforce fail at pybind_state.h:423] . Exception encountered running PythonOp function: ValueError: min() arg is an empty sequence

@rbgirshick
Copy link
Contributor

No details for reproducing given. @junxiaoge feel free to reopen if you fill out the issue template.

@neeraj-j
Copy link

This may be due to error in Segment data.
The error in this case is happening at "x0 = min(min(p[::2]) for p in poly) ". It means the "p" i.e segment is empty list.
Please check if any of your "segmentation" field in .json file has len("segmentation") <= 6.
Ref to the code in json_dataset.py
# Valid polygons have >= 3 points, so require >= 6 coordinates
obj['segmentation'] = [
p for p in obj['segmentation'] if len(p) >= 6
]

@rudy-letote
Copy link

rudy-letote commented Nov 30, 2018

@neeraj-j

thank you for you suggestion ,i have borried for this problem for two days.this happens is because of using my own datasets

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

4 participants