[Insight-users] Problems compiling ITK4.4 with Java wrapping

Bradley Lowekamp blowekamp at mail.nih.gov
Mon Jul 15 08:19:43 EDT 2013


Mathew,

Here is a quick response. 

I'd check the ITK dashboard[1] to see if any of the WrapITK builds have JAVA turned on. This will help tell  you if it is supported. I have never used the WrapITK Java bindings, but I do use the python ones. Likely the Java binding are not being actively maintained by anyone in the community and need a little TLC.

I believe you are interested the LevelSetsv4 module. If you look in that module directory in ITK[2], you will see that it's missing a "wrapping" directory. This means that no one has written the little bit of CMake template instantiation that is need.

So with a bit of work this should be do able.


Alternatively, you could use the SimpleITK infrastructure and just write a custom SimpleITK filter inside that repo, I'd think this would be the quickest to get something.

Lastly, it would be good to get some of the modular plug-able v4 Levelsets in to SimpleITK proper. Likely some serious design need to occur to get that so it'll be powerful and meet most peoples needs. It's something I'd like to do when I get time and help would be quite useful

[1] http://open.cdash.org/index.php?project=Insight
[2] https://github.com/Kitware/ITK/tree/master/Modules/Segmentation/LevelSetsv4

p.s. I thought I sent this e-mail on Saturday, but it doesn't look like it got through.

On Jul 13, 2013, at 9:23 PM, Bradley Lowekamp <brad at lowekamp.net> wrote:

> Mathew,
> 
> Here is a quick response. 
> 
> I'd check the ITK dashboard[1] to see if any of the WrapITK builds have JAVA turned on. This will help tell  you if it is supported. I have never used the WrapITK Java bindings, but I do use the python ones. Likely the Java binding are not being actively maintained by anyone in the community and need a little TLC.
> 
> I believe you are interested the LevelSetsv4 module. If you look in that module directory in ITK[2], you will see that it's missing a "wrapping" directory. This means that no one has written the little bit of CMake template instantiation that is need.
> 
> So with a bit of work this should be do able.
> 
> 
> Alternatively, you could use the SimpleITK infrastructure and just write a custom SimpleITK filter inside that repo, I'd think this would be the quickest to get something.
> 
> Lastly, it would be good to get some of the modular plug-able v4 Levelsets in to SimpleITK proper. Likely some serious design need to occur to get that so it'll be powerful and meet most peoples needs. It's something I'd like to do when I get time and help would be quite useful
> 
> 
> 
> [1] http://open.cdash.org/index.php?project=Insight
> [2] https://github.com/Kitware/ITK/tree/master/Modules/Segmentation/LevelSetsv4
> On Jul 13, 2013, at 11:06 AM, Mathew Guilfoyle <mrguilfoyle at gmail.com> wrote:
> 
>> Hi,
>> 
>> I would appreciate some pointers on compiling ITK 4.4 with the Java wrapper.
>> 
>> I have been using the SimpleITK Java binary successfully within Matlab but want to try out some of the level set filters in ITK that are not yet available in SimpleITK.  Since Matlab supports Java natively it would be the easiest way of using ITK.
>> 
>> I am entirely new to the process of using Cmake and compiling with Visual Studio 2012
>> 
>> System: Win 8 x64 Professional, Cmake 2.8.11.2, VS 2012 with all updates.
>> 
>> I have succesfully compiled ITK with the TESTING and EXAMPLES Cmake flags off and BUILD_SHARED_LIBS on.  I find a ITKCommon-4.4.dll in the /bin/debug subdirectory of my build folder.  Having said this I don't know exactly what I should expect to find after a succesful build, but VS does not report any errors.  (Incidental question - does the above dll contain all the ITK functions?  Is there a header file for this?)
>> 
>> If I turn on the ITK_WRAP_JAVA flag I get a Cmake error: 
>> 
>> CMake Error at Wrapping/Generators/Java/CMakeLists.txt:39 (list):
>> list sub-command REMOVE_ITEM requires list to be present.
>> 
>> As mentioned in another thread I've inspected the CMakeLists.txt in the error message and there is a "To-do" comment! - is Java wrapping simply broken currently?
>> 
>> NB Cmake correctly finds all elements of the JDK as far as I can see.
>> 
>> I have generated the build despite the above error and then run the compilation in VS.  Everything works well for a while and then I get a whole series of errors of the same form
>> 
>> Error	469	error MSB6006: "cmd.exe" exited with code 1.	C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.CppCommon.targets	172	5	ITKFastMarchingJavaJar
>> 
>> In each of these (481 in total) the file mentioned at the end is different but otherwise the message is the same.
>> 
>> Can anyone direct me to a way of resolving this?
>> 
>> Cheers
>> Mat
>> _____________________________________
>> 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://www.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-users
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20130715/13ded63d/attachment.htm>


More information about the Insight-users mailing list