Calling cv2.GrabCut() on a large image crashes Python interpreter (Bug #3468)
Description
Tested on OpenCV versions 2.4.6 and 2.4.7
Environment: Python 2.7.2 (x86) run under Windows 7 (x64)
Test script attached.
Image 'image.png' can be found here (6+ MB): http://vindicar.name/misc/image.png
Initial mask 'mask.png' can be found here: http://vindicar.name/misc/mask.png
When image is downsampled, function works just fine.
Is it possible for cv2.GrabCut() to circumvent such a situation, or at least to detect it beforehand?
Associated revisions
Merge pull request #3468 from StevenPuttemans:fix_models
History
Updated by Anna Kogan about 11 years ago
Hello Alex,
Thank you for reporting the problem and especially for providing the reproducer. If you could work on a solution on your side, a contribution (see How_to_contribute) would be very appreciated!
- Affected version changed from 2.4.7 (latest release) to branch '2.4' (2.4-dev)
- Assignee changed from Vadim Pisarevsky to Alex Orlov
Updated by Anna Kogan about 11 years ago
- Status changed from New to Open
Updated by Maksim Shabunin over 9 years ago
Issue has been transferred to GitHub: https://github.com/Itseez/opencv/issues/4675