You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2017/12/12 23:05:29 UTC

[GitHub] zhreshold commented on a change in pull request #8547: Revised validating process of a bounding box in ImageDetIter

zhreshold commented on a change in pull request #8547: Revised validating process of a bounding box in ImageDetIter
URL: https://github.com/apache/incubator-mxnet/pull/8547#discussion_r156522021
 
 

 ##########
 File path: python/mxnet/image/detection.py
 ##########
 @@ -726,10 +726,23 @@ def _parse_label(self, label):
                 %(str(raw.shape), obj_width)
             raise RuntimeError(msg)
         out = np.reshape(raw[header_width:], (-1, obj_width))
-        # remove bad ground-truths
-        valid = np.where(np.logical_and(out[:, 3] > out[:, 1], out[:, 4] > out[:, 2]))[0]
+
+        # remove invalid ground-truths
+        if ((obj_width - 1) / 4) == 1:
 
 Review comment:
   In fact, it is not safe to check the length of object, since user may append additional info to the objects, not necessarily polygon label.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services