For rotated proposals, replace cv::rotatedRectangleIntersection with a correct versio...
authorJing Huang <jinghuang@fb.com>
Fri, 14 Dec 2018 02:10:55 +0000 (18:10 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Fri, 14 Dec 2018 02:13:46 +0000 (18:13 -0800)
commitdc72a5e02c1ecb105ea58cafcf10ef3a6f7d9c25
treea05e617408e9d86750e03da638514675d733e42b
parentaecab53778024d7686661bf60b3726c7a82f4a04
For rotated proposals, replace cv::rotatedRectangleIntersection with a correct version that doesn't have underflow problem (#15113)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/15113

cv::rotatedRectangleIntersection has a known float underflow bug that would cause failure in ```CV_Assert(intersection.size() <= 8)```

For rotated proposals, replace cv::rotatedRectangleIntersection with a correct version that doesn't have underflow problem.

Otherwise, when ```USE_CPP_GENERATE_PROPOSALS = true```, the training would fail.

Reviewed By: viswanathgs

Differential Revision: D13429770

fbshipit-source-id: 5e95d059f3c668f14059a0a83e8e53d8554cdb99
caffe2/operators/generate_proposals_op_util_nms.h