Installing Elastix

354 views
Skip to first unread message

Hussam Jassim

unread,
Aug 13, 2021, 2:10:28 AM8/13/21
to elastix-imageregistration

Dear Developers,


Good evening,

I am a new user to Elastix, and I am now working on Windows-10 operation system. I have downloaded ITK version 5.2.0 and compiled it according to the recommendation in Elastix manual. 

Then I copied the (''CMakeLists.txt'') from  (https://github.com/SuperElastix/elastix/blob/develop/CMakeLists.txt) and compiled the Elastix using Cmake as well. However, when I compile elastix foder I have this popup (''   Error in configuration process, project file may be invalid ') and on output of Cmake  this error occurs ('' CMake Error at CMakeLists.txt:74 (include):

include could not find requested file:

elastixVersion

CMake Error at CMakeLists.txt:77 (include):
include could not find requested file:

elastixExportTarget

CMake Error at CMakeLists.txt:330 (add_subdirectory):
add_subdirectory given source "Common" which is not an existing directory.

CMake Error at CMakeLists.txt:334 (add_subdirectory):
add_subdirectory given source "Components" which is not an existing
directory.

CMake Error at CMakeLists.txt:338 (add_subdirectory):
add_subdirectory given source "Core" which is not an existing directory.

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/example.bat does not exist.

CMake Error at CMakeLists.txt:351 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/fixed.mhd does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/fixed.raw does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/mask_fixed.mhd does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/mask_fixed.raw does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/mask_moving.mhd does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/mask_moving.raw does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/moving.mhd does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/moving.raw does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/parameters_Affine.txt does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/parameters_BSpline.txt does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/parameters_Rigid.txt does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/parameters_Translation.txt does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/solution_deformedmovingimage.mhd does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error: File F:/Elastix/Elastix/elastix-5.0.1-win64/elastix-5.0.1-win64/dox/exampleinput/solution_deformedmovingimage.raw does not exist.

CMake Error at CMakeLists.txt:383 (configure_file):
configure_file Problem configuring file

CMake Error at CMakeLists.txt:437 (add_subdirectory):
add_subdirectory given source "Testing" which is not an existing directory.

CMake Error at CMakeLists.txt:594 (elastix_export_target):

Unknown CMake command "elastix_export_target".'').


Could you please tell me how I can solve this problem?


Yours sincerely

M.St...@lumc.nl

unread,
Aug 13, 2021, 6:27:54 AM8/13/21
to elastix-imag...@googlegroups.com
Dear Hussam,

Section 3.2 of the manual gives some information on how to compile elastix. You need to point elastix to the binary directory of the ITK using the ITK_DIR option. There should be no need to copy the CMakeLists file, it is in exactly the correct location.

Please let us know if these bits help to get it compiled.

Best, Marius



From: elastix-imag...@googlegroups.com <elastix-imag...@googlegroups.com> on behalf of Hussam Jassim <husja...@gmail.com>
Sent: 12 August 2021 10:28 PM
To: elastix-imageregistration
Subject: [elastix-imageregistration] Installing Elastix
 
Dear Developers,

Good evening,

I am a new user to Elastix, and I am now working on Windows-10 operation system. I have downloaded ITK version 5.2.0 and compiled it according to the recommendation in Elastix manual. 

Then I copied the (''CMakeLists.txt'') from  (https://github.com/SuperElastix/elastix/blob/develop/CMakeLists.txt) and compiled the Elastix using Cmake as well. However, when I compile elastix foder I have this popup (''   Error in configuration process, project file may be invalid ') and on output of Cmake  this error occurs ('' Add the installation prefix of "ITK" to CMAKE_PREFIX_PATH or set "ITK_DIR" to a directory containing one of the above files. If "ITK" provides a
separate development package or SDK, be sure it has been installed.'').


Could you please tell me how I can solve this problem, for example for which file I set "ITK_DIR"?


Yours sincerely 


--
You received this message because you are subscribed to the Google Groups "elastix-imageregistration" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elastix-imageregis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elastix-imageregistration/2ae50bb1-86ea-46ec-a475-e4c9fb1fc3e7n%40googlegroups.com.

Hussam Jassim

unread,
Aug 13, 2021, 11:30:05 AM8/13/21
to elastix-imageregistration
Dear Dr. Staring,

Than you for your reply, 
When I do not create text file that contains the code of CMakeLists.txt posted on (https://github.com/SuperElastix/elastix/blob/develop/CMakeLists.txt), Elastix code is not configured and I have this error

''CMake Error: The source directory "F:/Elastix/Elastix/elastix-5.0.1-win64/Elastix_Build_5.0.1" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI
''.

Actually, I downlowded ''elastix-5.0.1-win64.zip'' as a source because I use Windows 7, 64 bit. 


Yours sincerely


M.St...@lumc.nl

unread,
Aug 25, 2021, 10:00:37 AM8/25/21
to elastix-imag...@googlegroups.com

Dear Hussam,


Were you able to cmake and compile the ITK first?

After that run CMake on the elastix sources, without copying files around, and pointing ITK_DIR to the binary directory of ITK, and you should be good generating project files for elastix.


HTH, Marius



Sent: 13 August 2021 5:30 PM
To: elastix-imageregistration
Subject: Re: [elastix-imageregistration] Installing Elastix
 
Dear Dr. Staring,

Than you for your reply, 
When I do not create text file that contains the code of CMakeLists.txt posted on (https://github.com/SuperElastix/elastix/blob/develop/CMakeLists.txt), Elastix code is not configured and I have this error
Official elastix repository. Contribute to SuperElastix/elastix development by creating an account on GitHub.
Reply all
Reply to author
Forward
0 new messages