Ask Your Question
0

Segmentation fault.. using opencv_createsamples

asked 2018-03-06 10:35:54 -0500

updated 2018-08-29 08:33:13 -0500

image descriptionhope you are fine. I was following this tutorial to create my own cascade: https://pythonprogramming.net/haar-ca... ... when I try to create test samples .. it gives me this error --> Create test samples from single image applying distortions... Segmentation fault (core dumped). image description it will be really great if you can help

edit retag flag offensive close merge delete

Comments

1

did you use the the latest source (there is recent fixes)

sturkmen gravatar imagesturkmen ( 2018-03-06 10:42:26 -0500 )edit

please replace the screenshots with a TEXT version, so ppl can quote you, thank you..

berak gravatar imageberak ( 2018-03-06 11:02:17 -0500 )edit
1
  • Create test samples from single image applying distortions -- that idea never works with objects in the real world. get a ton of real images instead
  • the segmentation might be a bug (can't find the link, sorry). try to update to latest master
berak gravatar imageberak ( 2018-03-06 11:27:07 -0500 )edit

It worked. Thanks!

basmabashir gravatar imagebasmabashir ( 2018-03-12 14:10:05 -0500 )edit

same error to me.....can anyone tel me how can i solve this?

usuf gravatar imageusuf ( 2018-03-27 02:43:31 -0500 )edit

@usuf - what is unclear in "update to latest master" ?

berak gravatar imageberak ( 2018-03-27 02:45:23 -0500 )edit
1

yeah i replace the code with new one...but not work

usuf gravatar imageusuf ( 2018-03-27 02:47:31 -0500 )edit

anyone have the answer.....i have new opencv master file..... but when i am using create sample command it shows the segmentation problem error?

usuf gravatar imageusuf ( 2018-03-29 00:49:51 -0500 )edit

@usuf, please do not post answers here, if you have a question or comment, thank you .

berak gravatar imageberak ( 2018-03-29 01:07:48 -0500 )edit

hi i am update the opencv with latest master still it shows segmentation program do u have any idea about this?

usuf gravatar imageusuf ( 2018-04-02 23:23:47 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2020-07-03 17:20:47 -0500

in apps/createsamples/utility.cpp commenting out this line (line 552 in opencv 3.4.4) worked for me

after commenting out that line then "make" opencv again it should scan past everything else and just make createsamples

static int icvStartSampleDistortion( const char* imgfilename, int bgcolor, int bgthreshold,
                              CvSampleDistortionData* data )
{
//    memset( data, 0, sizeof( *data ) );

Can't take credit, my son saw it right off the bat looking at the code. Best thing ever for a dad, seeing you kids becoming better than you are.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-03-06 10:35:54 -0500

Seen: 934 times

Last updated: Mar 29 '18