Le 29/06/2012 11:15, pj gouttenoire a écrit :
Hello,

i use itk::RegularStepGradientDescentBaseOptimizer for computing path between structures, the first version is doing in a for loop and one by one and it works, but it's very long so i use openMP for parallel computation. I made the directive fot the for loop and i launch it in multprocessor and i have this seg fault

Program received signal SIGSEGV, Segmentation fault.

[Switching to Thread 1126189376 (LWP 17584)]
0x00000000004be7d4 in itk::LinearInterpolateImageFunction<itk::Image<double, 3u>, double>::EvaluateAtContinuousIndex (
this=0x2aaabc028150, index=@0x43202c70)
at /data/id19/bones/Creatis/All/thirdparty_install/include/InsightToolkit/Common/itkLinearInterpolateImageFunction.txx:150 150 value += static_cast<RealType>( this->GetInputImage()->GetPixel( neighIndex ) ) * overlap;
(gdb) bt
#0 0x00000000004be7d4 in itk::LinearInterpolateImageFunction<itk::Image<double, 3u>, double>::EvaluateAtContinuousIndex (
this=0x2aaabc028150, index=@0x43202c70)
at /data/id19/bones/Creatis/All/thirdparty_install/include/InsightToolkit/Common/itkLinearInterpolateImageFunction.txx:150 #1 0x00000000004bcc9e in itk::InterpolateImageFunction<itk::Image<double, 3u>, double>::Evaluate (this=0x2aaabc028150,
point=@0x43202d00)
at /data/id19/bones/Creatis/All/thirdparty_install/include/InsightToolkit/Common/itkInterpolateImageFunction.h:93 #2 0x000000000046c406 in itk::PhysicalCentralDifferenceImageFunction<itk::Image<double, 3u>, double>::Evaluate (
this=0x2aaabc027360, point=@0x43202db0)
at /data/id19/bones2/maria/linux/source/lcNetwork/Src/FastMarching/itkPhysicalCentralDifferenceImageFunction.txx:65 #3 0x00000000004b8dbe in itk::SingleImageCostFunction<itk::Image<double, 3u> >::GetDerivative (this=0x2aaab8033a20,
parameters=@0x2aaab9740790, derivative=@0x2aaab97407e0)
at /data/id19/bones2/maria/linux/source/lcNetwork/Src/FastMarching/itkSingleImageCostFunction.txx:136 #4 0x00000000004627f2 in itk::SingleValuedCostFunction::GetValueAndDerivative (this=0x2aaab8033a20, parameters=@0x2aaab9740790, value=@0x2aaab9740818, derivative=@0x2aaab97407e0) at /data/id19/bones/Creatis/All/thirdparty_install/include/InsightToolkit/Numerics/itkSingleValuedCostFunction.h:76 #5 0x00002aaaabd4fc57 in itk::RegularStepGradientDescentBaseOptimizer::ResumeOptimization () from /data/id19/bones/Creatis/All/thirdparty_install/lib/InsightToolkit/libITKNumerics.so.3.20 #6 0x00002aaaabd503b9 in itk::RegularStepGradientDescentBaseOptimizer::StartOptimization () from /data/id19/bones/Creatis/All/thirdparty_install/lib/InsightToolkit/libITKNumerics.so.3.20 #7 0x00000000004ba2ce in itk::ArrivalFunctionToPathFilter<itk::Image<double, 3u>, itk::PolyLineParametricPath<3u> >::GenerateData (this=0x2aaabc026f60) at /data/id19/bones2/maria/linux/source/lcNetwork/Src/FastMarching/itkArrivalFunctionToPathFilter.txx:199 #8 0x00000000004ba752 in itk::SpeedFunctionToPathFilter<itk::Image<double, 3u>, itk::PolyLineParametricPath<3u> >::GenerateData (this=0x2aaabc026f60) at /data/id19/bones2/maria/linux/source/lcNetwork/Src/FastMarching/itkSpeedFunctionToPathFilter.txx:185
#9 0x00002aaab313e7af in itk::ProcessObject::UpdateOutputData ()
from /data/id19/bones/Creatis/All/thirdparty_install/lib/InsightToolkit/libITKCommon.so.3.20
#10 0x00002aaab30fb192 in itk::DataObject::UpdateOutputData ()
from /data/id19/bones/Creatis/All/thirdparty_install/lib/InsightToolkit/libITKCommon.so.3.20
#11 0x00002aaab30fb0b6 in itk::DataObject::Update ()
from /data/id19/bones/Creatis/All/thirdparty_install/lib/InsightToolkit/libITKCommon.so.3.20
#12 0x00002aaab313dd51 in itk::ProcessObject::Update ()
from /data/id19/bones/Creatis/All/thirdparty_install/lib/InsightToolkit/libITKCommon.so.3.20
#13 0x00000000004605da in calculFastMarching (startfile=
{static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>}, _M_p = 0x43204050 "�q'\n"}}, endfile= {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>}, _M_p = 0x43204040 "\210r'\n"}}, startindex=1, debug=1, advanced=false,
vote=0.050000000000000003, inputfile=
{static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>}, _M_p = 0x43204030 "�p'\n"}}, addImage={m_Pointer = 0x43204020}) at /data/id19/bones2/maria/linux/source/lcNetwork/Apps/FastMarching/fastmarchingTestMP.cxx:306
#14 0x000000000046210c in main.omp_fn.0 (.omp_data_i=0x7fff042f66b0)
at /data/id19/bones2/maria/linux/source/lcNetwork/Apps/FastMarching/fastmarchingTestMP.cxx:191 #15 0x00002aaab59ce4ac in GOMP_single_copy_start () from /usr/lib64/libgomp.so.1
#16 0x00002aaab479d2e7 in start_thread () from /lib64/libpthread.so.0
#17 0x0000003caf4ce3bd in clone () from /lib64/libc.so.6


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Kitware offers ITK Training Courses, for more information visit:
http://kitware.com/products/protraining.php

Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.itk.org/mailman/listinfo/insight-developers

i'm using itk 3.20


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Kitware offers ITK Training Courses, for more information visit:
http://kitware.com/products/protraining.php

Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.itk.org/mailman/listinfo/insight-developers

Reply via email to