LineSegmentDetector in Python supports only LSD_REFINE_ADV flag (Bug #3709)


Added by abid rahman almost 11 years ago. Updated almost 10 years ago.


Status:Done Start date:2014-05-23
Priority:Normal Due date:
Assignee:Andrey Pavlenko % Done:

0%

Category:python bindings
Target version:3.0
Affected version:branch 'master' (3.0-dev) Operating System:Any
Difficulty: HW Platform:Any
Pull request:https://github.com/Itseez/opencv/pull/2824

Description

For LineSegmentDetector, python bindings support only LSD_REFINE_ADV flag. For other two flags, it throws assertion error.

img = cv2.imread('test.jpg',0)
LSD = cv2.createLineSegmentDetector(0) # LSD_REFINE_NONE
a = LSD.detect(img)

OpenCV Error: Assertion failed ((!_nfa.needed()) || (_nfa.needed() && doRefine >= LSD_REFINE_ADV)) in detect, file /run/media/abidrahmank/OFFICE/repos/opencv/modules/imgproc/src/lsd.cpp, line 431

It is caused due to inability to pass optional output argument in Python bindings.


Associated revisions

Revision 90fb43cd
Added by Vadim Pisarevsky about 10 years ago

Merge pull request #3709 from StevenPuttemans:fix_traincascade_load_message_master

History

Updated by Dmitry Retinskiy almost 11 years ago

Hi Andrey,

could you check this issue?
Thanks.

  • Assignee changed from abid rahman to Andrey Pavlenko

Updated by Maksim Shabunin almost 10 years ago

  • Status changed from New to Done
  • Pull request set to https://github.com/Itseez/opencv/pull/2824

Also available in: Atom PDF