Ask Your Question
0

surface_matching code stuck on training

asked 2017-09-13 14:03:38 -0600

elfid gravatar image

updated 2017-09-13 14:21:15 -0600

Hello, I'm trying to use the surface matching but I dont know why it is taking a long time training.

System information:

OpenCV => 3.3.0

Operating System / Platform => Windows 10 64 Bit

Compiler => Visual Studio 2017

Description

I ran the sample code "ppf_load_match.cpp", that first gave me the error on variable "hashKey", which I resolved as in Here.

After that the code runs without errors, but it is stuck on "Training...". I'm concerned as it should take aroud 30 sec to complete that task but I have run the program for more than 30 minutes with different arguments and it is still stuck.

I have changed the parameters in line 109 (detector.match(pcTest, results, 1.0/40.0, 0.05);) as said Here and still nothing changes.

Is there anything else I can do to fix this? I could not find anything like this problem with same system as me.

EDIT: When I stop the program there is a line of error:

Run-Time Check Failure #2 - Stack around the variable 'hashKey' was corrupted

edit retag flag offensive close merge delete

Comments

I have tried with VS2015, and still the same error: Run-Time Check Failure #2 - Stack around the variable 'hashKey' was corrupted

elfid gravatar imageelfid ( 2017-09-15 12:05:24 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2017-09-13 14:58:21 -0600

LBerger gravatar image

No problem with VS2015 (and modification). I run program in release ( or in debug) with this arguments

g:/lib/opencv_contrib/modules/surface_matching/samples/data/parasaurolophus_6700.ply g:/lib/opencv_contrib/modules/surface_matching/samples/data/parasaurolophus_low_normals2.ply

Results are :

****************************************************
* Surface Matching demonstration : demonstrates the use of surface matching using point pair features.
* The sample loads a model and a scene, where the model lies in a different pose than the training.
* It then trains the model and searches for it in the input scene. The detected poses are further refined by ICP
* and printed to the  standard output.
****************************************************
Running on 64 bits
Running without OpenMP and without TBB
Training...

Training complete in 14.1909 sec
Loading model...

Starting matching...

PPF Elapsed Time 0.781114 sec
Number of matching poses: 19
Performing ICP on 2 poses...

ICP Elapsed Time 0.650314 sec
Poses:
Pose Result 0

-- Pose to Model Index 67: NumVotes = 954, Residual = 0.002882
1.000000 0.000050 -0.000096 -0.059459
-0.000050 1.000000 0.000053 0.038520
0.000096 -0.000053 1.000000 -0.007783
0.000000 0.000000 0.000000 1.000000

Pose Result 1

-- Pose to Model Index 225: NumVotes = 682, Residual = 0.002831
1.000000 0.000049 -0.000090 -0.057513
-0.000049 1.000000 0.000039 0.027504
0.000090 -0.000039 1.000000 -0.007792
0.000000 0.000000 0.000000 1.000000

Appuyez sur une touche pour continuer...
edit flag offensive delete link more

Comments

I am facing this problem on VS-2015 opencv 4.0.0 Do you know how to solve it? win-64 bit

Joy Mazumder gravatar imageJoy Mazumder ( 2018-10-19 19:22:07 -0600 )edit

I have just try ths morning (20181020 6:44 gmt) there is no problem

LBerger gravatar imageLBerger ( 2018-10-20 02:45:10 -0600 )edit

which version of OS and OpenCV are you using? I tried with the supplied model but still same error

Joy Mazumder gravatar imageJoy Mazumder ( 2018-10-20 14:38:42 -0600 )edit

Windows 10 vs 2017-Win64

LBerger gravatar imageLBerger ( 2018-10-21 02:55:10 -0600 )edit
1

This problem is solved now. I change the source and build again

Joy Mazumder gravatar imageJoy Mazumder ( 2018-10-23 11:09:57 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2017-09-13 14:03:38 -0600

Seen: 709 times

Last updated: Sep 13 '17