varuncnitw / geodesic

Automatically exported from code.google.com/p/geodesic
0 stars 0 forks source link

segmentation fault on 32-bit ubuntu #3

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1.
2.
3.

What is the expected output? What do you see instead?
Traceback:

Program received signal SIGSEGV, Segmentation fault.
0xb336a6da in geodesic::GeodesicAlgorithmExact::check_stop_conditions 
(this=0xa25e190, sources=..., 
    max_propagation_distance=1e+100, stop_points=0x0) at geodesic_library/geodesic_algorithm_exact.h:683
683     double queue_distance = (*m_queue.begin())->min();
Current language:  auto
The current source language is "auto; currently c++".
(gdb) backtrace
#0  0xb336a6da in geodesic::GeodesicAlgorithmExact::check_stop_conditions 
(this=0xa25e190, sources=..., 
    max_propagation_distance=1e+100, stop_points=0x0) at geodesic_library/geodesic_algorithm_exact.h:683
#1  geodesic::GeodesicAlgorithmExact::propagate (this=0xa25e190, sources=..., 
max_propagation_distance=1e+100, 
    stop_points=0x0) at geodesic_library/geodesic_algorithm_exact.h:555
#2  0xb3358423 in __pyx_pf_5gdist_compute_gdist (__pyx_self=<value optimized 
out>, 
    __pyx_v_vertices=<value optimized out>, __pyx_v_triangles=0x1268b028, __pyx_v_source_indices=0xa2f2370, 
    __pyx_v_target_indices=0xb7fa9680, __pyx_v_max_distance=1e+100) at gdist.cpp:1815
#3  0xb335a0c6 in __pyx_pw_5gdist_1compute_gdist (__pyx_self=0x0, 
__pyx_args=0x8c81f0c, __pyx_kwds=0x13da757c)
    at gdist.cpp:1430
#4  0xb7ebf178 in PyCFunction_Call (func=0xb2f956c, arg=0x8c81f0c, 
kw=0x13da757c) at Objects/methodobject.c:85
#5  0xb7f24231 in do_call (f=0xa260634, throwflag=0) at Python/ceval.c:4236
#6  call_function (f=0xa260634, throwflag=0) at Python/ceval.c:4044
#7  PyEval_EvalFrameEx (f=0xa260634, throwflag=0) at Python/ceval.c:2666

What version of the product are you using? On what operating system?

latest code, Debian GNU/Linux 6.0, 32 bit

Please provide any additional information below.

I'm using this in a python wrapper. Everything worked fine with default debian 
python 2.6.6. Now I switched to 2.7.3 and rebuilt gdist.so, seems to work fine 
for lower vertices, but on a larger surface (~40.000 * 3 vertices) I get the 
above error. Any pointers would be a great help?

Original issue reported on code.google.com by bogdan.v...@gmail.com on 16 May 2013 at 3:52

GoogleCodeExporter commented 8 years ago
Segmentation Fault happens when calling (from our python wrapper):
GeodesicAlgorithmExact::propagate(vertex_source_array, 1e100, NULL)

If we decrease parameter max_propagation_distance to a reasonable small value, 
our call seems to be working:
GeodesicAlgorithmExact::propagate(vertex_source_array, 
max_propagation_distance=150, NULL)

Anything bigger than 170 for max_propagation_distance parameter produces erors.

The machine I am testing is a Debian GNU/Linux 6.0 (Linux tvb-build-x86 
2.6.32-5-686-bigmem #1 SMP Mon Jan 16 16:42:05 UTC 2012 i686 GNU/Linux) 2GB RAM.

Does anyone have any ideas why this is happening ? It works fine for Linux x64 
(similar configuration)
Any hint on how we could avoid this, or what's a good value for parameter 
max_propagation_distance would be of great help.

Original comment by ldom...@gmail.com on 27 May 2013 at 2:52