When i try to run this code i obtain the following error:
File "/home/fhaouas/miniconda3/envs/ParaPET2/lib/python3.8/site-packages/SimpleITK/SimpleITK.py", line 11130, in Execute
return _SimpleITK.ElastixImageFilter_Execute(self)
RuntimeError: Exception thrown in SimpleITK ElastixImageFilter_Execute: /home/francesco/SimpleElastix/Code/Elastix/src/sitkElastixImageFilterImpl.cxx:259:
sitk::ERROR:
itk::ExceptionObject (0x559e30563e90)
Location: "unknown"
File: /home/francesco/SimpleElastix/build/Elastix/Core/Main/elxElastixFilter.hxx
Line: 253
Description: itk::ERROR: ElastixFilter(0x559e3b239fd0): Internal elastix error: See elastix log (use LogToConsoleOn() or LogToFileOn()).
Hi,
I'm trying to register DICOM images via SimpleElastix and i have tried to reproduce an existant code (https://github.com/SuperElastix/SimpleElastix):
import SimpleITK as sitk movingImage = sitk.ReadImage('/home/fhaouas/Bureau/Data/exported from ParaPET 2.0/Anonymous-02-31_FDG0/20210624-TEP iTEP PARAMETRIQUE/Anonymous-02-31_FDG0/20210624-TEP iTEP PARAMETRIQUE/SerieDyn/serie5/pet140.dcm') fixedImage = sitk.ReadImage('/home/fhaouas/Bureau/Data/exported from ParaPET 2.0/Anonymous-02-31_FDG0/20210624-TEP iTEP PARAMETRIQUE/Anonymous-02-31_FDG0/20210624-TEP iTEP PARAMETRIQUE/SerieDyn/serie6/pet140.dcm') selx = sitk.ElastixImageFilter() selx.SetMovingImage(movingImage) selx.SetParameterMap(selx.GetDefaultParameterMap('nonrigid')) selx.SetFixedImage(fixedImage) selx.Execute()
When i try to run this code i obtain the following error: File "/home/fhaouas/miniconda3/envs/ParaPET2/lib/python3.8/site-packages/SimpleITK/SimpleITK.py", line 11130, in Execute return _SimpleITK.ElastixImageFilter_Execute(self)
RuntimeError: Exception thrown in SimpleITK ElastixImageFilter_Execute: /home/francesco/SimpleElastix/Code/Elastix/src/sitkElastixImageFilterImpl.cxx:259: sitk::ERROR: itk::ExceptionObject (0x559e30563e90) Location: "unknown" File: /home/francesco/SimpleElastix/build/Elastix/Core/Main/elxElastixFilter.hxx Line: 253 Description: itk::ERROR: ElastixFilter(0x559e3b239fd0): Internal elastix error: See elastix log (use LogToConsoleOn() or LogToFileOn()).
Many thanks for your help