From cr at neuro.ma.uni-heidelberg.de Wed Feb 1 07:03:23 2017 From: cr at neuro.ma.uni-heidelberg.de (Chr. Rossmanith) Date: Wed, 1 Feb 2017 13:03:23 +0100 Subject: [ITK-users] Bug in example ImageFilter Message-ID: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Hi, I've just downloaded https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar which doesn't compile out of the box because ImageFilter.h tries to include ImageFilter.txx which does not exist - should be ImageFilter.hxx (or ImageFilter.hxx must be renamed to ImageFilter.txx). Regards, Christina Ro?manith From francois.budin at kitware.com Wed Feb 1 11:13:54 2017 From: francois.budin at kitware.com (Francois Budin) Date: Wed, 1 Feb 2017 11:13:54 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: Hello Christina, Thank you for the bug report. Could you create an issue and a pull-request to solve the problem in this repository: https://github.com/InsightSoftwareConsortium/ITKWikiExamples Thank you! Francois On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith < cr at neuro.ma.uni-heidelberg.de> wrote: > Hi, > > I've just downloaded https://github.com/lorensen/IT > KWikiExamplesTarballs/raw/master/ImageFilter.tar which doesn't compile > out of the box because ImageFilter.h tries to include ImageFilter.txx which > does not exist - should be ImageFilter.hxx (or ImageFilter.hxx must be > renamed to ImageFilter.txx). > > Regards, > > Christina Ro?manith > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From blowekamp at mail.nih.gov Wed Feb 1 15:48:45 2017 From: blowekamp at mail.nih.gov (Lowekamp, Bradley (NIH/NLM/LHC) [C]) Date: Wed, 1 Feb 2017 20:48:45 +0000 Subject: [ITK-users] [ITK] ITK_COMPILED_CXX_VERSION always set to 1997 on macOS In-Reply-To: References: Message-ID: Hi, I am running Xcode 8.2.1 OS 10.11, and cmake 3.4.3. I was not able to reproduce your problem. For a clean build directory I ran: cmake -DCMAKE_CXX_STANDARD=11 ~/src/ITK && grep ITK_COMPILED_CXX Modules/Core/Common/itkConfigure.h I got the following: #define ITK_COMPILED_CXX_STANDARD_VERSION 201103L #if ITK_COMPILED_CXX_STANDARD_VERSION > __cplusplus There did appear to be a problem with the preprocessor variable used in the version check which I addressed here: http://review.source.kitware.com/#/c/22021/ Perhaps you did not start with a clean build directory? Brad > On Jan 31, 2017, at 5:02 AM, Olivier Commowick wrote: > > Hello > > Thanks for your answer. I am running into this with Xcode 8.2.1, on a macOS 10.12, cmake version 3.6.2, and it happens already when compiling ITK itself. > > I did not put the flag you mentioned. I could try but it seems to me that the VXL part of ITK has the same kind of test and it works. I mean by this that there is a VXL_COMPILED_CXX_STANDARD_VERSION set up in the file Modules/ThirdParty/VNL/src/vxl/config/cmake/config/VXLIntrospectionConfig.cmake . And this one is automatically set to 201103L without needing the flags you mentioned. May be there is something in this cmake file that should be ported back to the ITK equivalent (that?s just a thought of course). > > Thanks > Olivier > >> On 23 Jan 2017, at 15:25, Lowekamp, Bradley (NIH/NLM/LHC) [C] wrote: >> >> Hello, >> >> What Xcode version are you using? Can you produce a simple CMake command line configuration to reproduce the problem? >> >> If you set "CMAKE_CXX_FLAGS=-std=c++11?, does the same problem occur? >> >> Thanks! >> Brad >> >>> On Jan 23, 2017, at 9:11 AM, Olivier Commowick wrote: >>> >>> Hello, >>> >>> While debugging something else, I realised that the ITK_COMPILED_CXX_VERSION variable in CMake is always set to 199711L on my macOS 10.12. It sounds weird to me since I am always compiling ITK by enforcing to use CMAKE_CXX_STANDARD to 11. >>> >>> It appears to me that Modules/Core/Common/CMakeLists.txt does this test and probably does not account for the fact that cmake uses the 2011 standard or something else. Would someone have any idea of how to correct this or if this is important or not ? >>> >>> Best >>> Olivier >>> >>> --- >>> >>> Olivier Commowick, Ph.D. >>> Research Scientist >>> INRIA Rennes - Bretagne Atlantique, VISAGES Team >>> Campus de Beaulieu >>> 35042 Rennes >>> FRANCE >>> >>> Phone: +33 2 99 84 25 92 >>> Email: Olivier.Commowick at inria.fr >>> Web: http://olivier.commowick.org/ >>> >>> >>> >>> >>> >>> _____________________________________ >>> 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://public.kitware.com/mailman/listinfo/insight-users >>> _______________________________________________ >>> Community mailing list >>> Community at itk.org >>> http://public.kitware.com/mailman/listinfo/community >> > > > --- > > Olivier Commowick, Ph.D. > Research Scientist > INRIA Rennes - Bretagne Atlantique, VISAGES Team > Campus de Beaulieu > 35042 Rennes > FRANCE > > Phone: +33 2 99 84 25 92 > Email: Olivier.Commowick at inria.fr > Web: http://olivier.commowick.org/ > > > > > From dzenanz at gmail.com Wed Feb 1 17:02:25 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Wed, 1 Feb 2017 17:02:25 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: Hi Christina, you should not create a pull request for that repository, but rather modify the example directly on the wiki . The repository is updated manually by an automated script which scrapes the wiki. I think that Bill usually invokes it. Regards, D?enan On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin wrote: > Hello Christina, > > Thank you for the bug report. Could you create an issue and a pull-request > to solve the problem in this repository: > https://github.com/InsightSoftwareConsortium/ITKWikiExamples > > Thank you! > Francois > > On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith < > cr at neuro.ma.uni-heidelberg.de> wrote: > >> Hi, >> >> I've just downloaded https://github.com/lorensen/IT >> KWikiExamplesTarballs/raw/master/ImageFilter.tar which doesn't compile >> out of the box because ImageFilter.h tries to include ImageFilter.txx which >> does not exist - should be ImageFilter.hxx (or ImageFilter.hxx must be >> renamed to ImageFilter.txx). >> >> Regards, >> >> Christina Ro?manith >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bill.lorensen at gmail.com Wed Feb 1 17:28:55 2017 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Wed, 1 Feb 2017 17:28:55 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: That is correct. Update the wiki version. On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: Hi Christina, you should not create a pull request for that repository, but rather modify the example directly on the wiki . The repository is updated manually by an automated script which scrapes the wiki. I think that Bill usually invokes it. Regards, D?enan On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin wrote: > Hello Christina, > > Thank you for the bug report. Could you create an issue and a pull-request > to solve the problem in this repository: > https://github.com/InsightSoftwareConsortium/ITKWikiExamples > > Thank you! > Francois > > On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith < > cr at neuro.ma.uni-heidelberg.de> wrote: > >> Hi, >> >> I've just downloaded https://github.com/lorensen/IT >> KWikiExamplesTarballs/raw/master/ImageFilter.tar which doesn't compile >> out of the box because ImageFilter.h tries to include ImageFilter.txx which >> does not exist - should be ImageFilter.hxx (or ImageFilter.hxx must be >> renamed to ImageFilter.txx). >> >> Regards, >> >> Christina Ro?manith >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dzenanz at gmail.com Wed Feb 1 18:02:17 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Wed, 1 Feb 2017 18:02:17 -0500 Subject: [ITK-users] Problem with ITK eigensystem In-Reply-To: <96DC429F-7F78-49D7-A026-930012074F27@inria.fr> References: <2444669A-4CBE-4C72-BB82-B3538C4513B1@inria.fr> <242A16CD-79C1-4427-94DB-3AFCD1A33851@inria.fr> <96DC429F-7F78-49D7-A026-930012074F27@inria.fr> Message-ID: Hi Olivier, I tried running you example. One thing struck me right away: ITK version is much slower (after a few minutes running in release mod I killed it) than VNL version (about a second in debug mode) for your input. I can't comment the patch content or the numeric stability. Perhaps Brad and Hans can pitch in? Regards, D?enan On Tue, Jan 31, 2017 at 11:24 AM, Olivier Commowick < Olivier.Commowick at inria.fr> wrote: > Hello, > > I think I have found a bug in the behaviour of ITK?s symmetric > eigensystem. In the attached link (http://olivier.commowick.org/ > tmp/Test.zip) you will find an example code and matrix that fails with it > and not with VNL?s symmetric eigensystem (run on macOS 10.12, Xcode 8.2.1). > > It seems to me that there are subtle differences in between ITK and VNL > versions, VNL being more robust (and the same as what Matlab gives, I > didn?t test python). Here is what I have found so far : > > - the hypothenuse function (hypot for ITK and pythag for VNL) do not get > always the exact same result up to a very far away decimal > - some loop indices were wrong I think in the ITK eigensystem. Some do > vary in the VNL version, not in ITK?s equivalent > > In the patch file attached, I have made a set of corrections that make > things in ITK eigensystem closer to VNL but still the ITK version fails. I > have to say I am getting completely lost here so I am calling upon the > community for help. If anyone knows this enough, could you try the test > attached and see if you have any ideas of what is going on. That would help > us a lot. > > The test attached can be compiled with cmake and run with the text file > included : ./test_eigensystem data.txt > > Thanks in advance > Olivier > > > > --- > > Olivier Commowick, Ph.D. > Research Scientist > INRIA Rennes - Bretagne Atlantique, VISAGES Team > Campus de Beaulieu > 35042 Rennes > FRANCE > > Phone: +33 2 99 84 25 92 <+33%202%2099%2084%2025%2092> > Email: Olivier.Commowick at inria.fr > Web: http://olivier.commowick.org/ > > > > > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Olivier.Commowick at inria.fr Thu Feb 2 03:27:31 2017 From: Olivier.Commowick at inria.fr (Olivier Commowick) Date: Thu, 2 Feb 2017 09:27:31 +0100 Subject: [ITK-users] Problem with ITK eigensystem In-Reply-To: References: <2444669A-4CBE-4C72-BB82-B3538C4513B1@inria.fr> <242A16CD-79C1-4427-94DB-3AFCD1A33851@inria.fr> <96DC429F-7F78-49D7-A026-930012074F27@inria.fr> Message-ID: <7FE2FD85-C0C9-47BD-AE85-9B6FE5E1ADE6@inria.fr> Hi, Thanks for your test. There might be a bug in my test or the way you ran it since for me it doesn?t take a few minutes but rather less than a second. That being said since it produces nans it might be that on some OS it goes into an infinite loop... Olivier > On 2 Feb 2017, at 00:02, D?enan Zuki? wrote: > > Hi Olivier, > > I tried running you example. One thing struck me right away: ITK version is much slower (after a few minutes running in release mod I killed it) than VNL version (about a second in debug mode) for your input. > > I can't comment the patch content or the numeric stability. Perhaps Brad and Hans can pitch in? > > Regards, > D?enan > > On Tue, Jan 31, 2017 at 11:24 AM, Olivier Commowick > wrote: > Hello, > > I think I have found a bug in the behaviour of ITK?s symmetric eigensystem. In the attached link (http://olivier.commowick.org/tmp/Test.zip ) you will find an example code and matrix that fails with it and not with VNL?s symmetric eigensystem (run on macOS 10.12, Xcode 8.2.1). > > It seems to me that there are subtle differences in between ITK and VNL versions, VNL being more robust (and the same as what Matlab gives, I didn?t test python). Here is what I have found so far : > > - the hypothenuse function (hypot for ITK and pythag for VNL) do not get always the exact same result up to a very far away decimal > - some loop indices were wrong I think in the ITK eigensystem. Some do vary in the VNL version, not in ITK?s equivalent > > In the patch file attached, I have made a set of corrections that make things in ITK eigensystem closer to VNL but still the ITK version fails. I have to say I am getting completely lost here so I am calling upon the community for help. If anyone knows this enough, could you try the test attached and see if you have any ideas of what is going on. That would help us a lot. > > The test attached can be compiled with cmake and run with the text file included : ./test_eigensystem data.txt > > Thanks in advance > Olivier > > > > --- > > Olivier Commowick, Ph.D. > Research Scientist > INRIA Rennes - Bretagne Atlantique, VISAGES Team > Campus de Beaulieu > 35042 Rennes > FRANCE > > Phone: +33 2 99 84 25 92 > Email: Olivier.Commowick at inria.fr > Web: http://olivier.commowick.org/ > > > > > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Olivier.Commowick at inria.fr Thu Feb 2 04:06:22 2017 From: Olivier.Commowick at inria.fr (Olivier Commowick) Date: Thu, 2 Feb 2017 10:06:22 +0100 Subject: [ITK-users] Problem with ITK eigensystem In-Reply-To: <7FE2FD85-C0C9-47BD-AE85-9B6FE5E1ADE6@inria.fr> References: <2444669A-4CBE-4C72-BB82-B3538C4513B1@inria.fr> <242A16CD-79C1-4427-94DB-3AFCD1A33851@inria.fr> <96DC429F-7F78-49D7-A026-930012074F27@inria.fr> <7FE2FD85-C0C9-47BD-AE85-9B6FE5E1ADE6@inria.fr> Message-ID: <779D7A51-94AE-4101-A70B-DEC837408DFC@inria.fr> Oh, and I remember only now : in fact it might just be that applying the patch I sent in the email solves this problem of infinite loop while still producing nan values > On 2 Feb 2017, at 09:27, Olivier Commowick wrote: > > Hi, > > Thanks for your test. There might be a bug in my test or the way you ran it since for me it doesn?t take a few minutes but rather less than a second. That being said since it produces nans it might be that on some OS it goes into an infinite loop... > > Olivier > >> On 2 Feb 2017, at 00:02, D?enan Zuki? > wrote: >> >> Hi Olivier, >> >> I tried running you example. One thing struck me right away: ITK version is much slower (after a few minutes running in release mod I killed it) than VNL version (about a second in debug mode) for your input. >> >> I can't comment the patch content or the numeric stability. Perhaps Brad and Hans can pitch in? >> >> Regards, >> D?enan >> >> On Tue, Jan 31, 2017 at 11:24 AM, Olivier Commowick > wrote: >> Hello, >> >> I think I have found a bug in the behaviour of ITK?s symmetric eigensystem. In the attached link (http://olivier.commowick.org/tmp/Test.zip ) you will find an example code and matrix that fails with it and not with VNL?s symmetric eigensystem (run on macOS 10.12, Xcode 8.2.1). >> >> It seems to me that there are subtle differences in between ITK and VNL versions, VNL being more robust (and the same as what Matlab gives, I didn?t test python). Here is what I have found so far : >> >> - the hypothenuse function (hypot for ITK and pythag for VNL) do not get always the exact same result up to a very far away decimal >> - some loop indices were wrong I think in the ITK eigensystem. Some do vary in the VNL version, not in ITK?s equivalent >> >> In the patch file attached, I have made a set of corrections that make things in ITK eigensystem closer to VNL but still the ITK version fails. I have to say I am getting completely lost here so I am calling upon the community for help. If anyone knows this enough, could you try the test attached and see if you have any ideas of what is going on. That would help us a lot. >> >> The test attached can be compiled with cmake and run with the text file included : ./test_eigensystem data.txt >> >> Thanks in advance >> Olivier >> >> >> >> --- >> >> Olivier Commowick, Ph.D. >> Research Scientist >> INRIA Rennes - Bretagne Atlantique, VISAGES Team >> Campus de Beaulieu >> 35042 Rennes >> FRANCE >> >> Phone: +33 2 99 84 25 92 >> Email: Olivier.Commowick at inria.fr >> Web: http://olivier.commowick.org/ >> >> >> >> >> >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> >> > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From Olivier.Commowick at inria.fr Thu Feb 2 04:09:20 2017 From: Olivier.Commowick at inria.fr (Olivier Commowick) Date: Thu, 2 Feb 2017 10:09:20 +0100 Subject: [ITK-users] [ITK] ITK_COMPILED_CXX_VERSION always set to 1997 on macOS In-Reply-To: References: Message-ID: Hi, Ok now I get it. I was on the release branch and your modification seems to be only in the master branch yet. With it included, I have the same behaviour as yours. Thanks Olivier > On 1 Feb 2017, at 21:48, Lowekamp, Bradley (NIH/NLM/LHC) [C] wrote: > > Hi, > > I am running Xcode 8.2.1 OS 10.11, and cmake 3.4.3. I was not able to reproduce your problem. > For a clean build directory I ran: > cmake -DCMAKE_CXX_STANDARD=11 ~/src/ITK && grep ITK_COMPILED_CXX Modules/Core/Common/itkConfigure.h > > I got the following: > #define ITK_COMPILED_CXX_STANDARD_VERSION 201103L > #if ITK_COMPILED_CXX_STANDARD_VERSION > __cplusplus > > There did appear to be a problem with the preprocessor variable used in the version check which I addressed here: > http://review.source.kitware.com/#/c/22021/ > > Perhaps you did not start with a clean build directory? > > Brad > >> On Jan 31, 2017, at 5:02 AM, Olivier Commowick wrote: >> >> Hello >> >> Thanks for your answer. I am running into this with Xcode 8.2.1, on a macOS 10.12, cmake version 3.6.2, and it happens already when compiling ITK itself. >> >> I did not put the flag you mentioned. I could try but it seems to me that the VXL part of ITK has the same kind of test and it works. I mean by this that there is a VXL_COMPILED_CXX_STANDARD_VERSION set up in the file Modules/ThirdParty/VNL/src/vxl/config/cmake/config/VXLIntrospectionConfig.cmake . And this one is automatically set to 201103L without needing the flags you mentioned. May be there is something in this cmake file that should be ported back to the ITK equivalent (that?s just a thought of course). >> >> Thanks >> Olivier >> >>> On 23 Jan 2017, at 15:25, Lowekamp, Bradley (NIH/NLM/LHC) [C] wrote: >>> >>> Hello, >>> >>> What Xcode version are you using? Can you produce a simple CMake command line configuration to reproduce the problem? >>> >>> If you set "CMAKE_CXX_FLAGS=-std=c++11?, does the same problem occur? >>> >>> Thanks! >>> Brad >>> >>>> On Jan 23, 2017, at 9:11 AM, Olivier Commowick wrote: >>>> >>>> Hello, >>>> >>>> While debugging something else, I realised that the ITK_COMPILED_CXX_VERSION variable in CMake is always set to 199711L on my macOS 10.12. It sounds weird to me since I am always compiling ITK by enforcing to use CMAKE_CXX_STANDARD to 11. >>>> >>>> It appears to me that Modules/Core/Common/CMakeLists.txt does this test and probably does not account for the fact that cmake uses the 2011 standard or something else. Would someone have any idea of how to correct this or if this is important or not ? >>>> >>>> Best >>>> Olivier >>>> >>>> --- >>>> >>>> Olivier Commowick, Ph.D. >>>> Research Scientist >>>> INRIA Rennes - Bretagne Atlantique, VISAGES Team >>>> Campus de Beaulieu >>>> 35042 Rennes >>>> FRANCE >>>> >>>> Phone: +33 2 99 84 25 92 >>>> Email: Olivier.Commowick at inria.fr >>>> Web: http://olivier.commowick.org/ >>>> >>>> >>>> >>>> >>>> >>>> _____________________________________ >>>> 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://public.kitware.com/mailman/listinfo/insight-users >>>> _______________________________________________ >>>> Community mailing list >>>> Community at itk.org >>>> http://public.kitware.com/mailman/listinfo/community >>> >> >> >> --- >> >> Olivier Commowick, Ph.D. >> Research Scientist >> INRIA Rennes - Bretagne Atlantique, VISAGES Team >> Campus de Beaulieu >> 35042 Rennes >> FRANCE >> >> Phone: +33 2 99 84 25 92 >> Email: Olivier.Commowick at inria.fr >> Web: http://olivier.commowick.org/ >> >> >> >> >> > From Olivier.Commowick at inria.fr Thu Feb 2 05:24:55 2017 From: Olivier.Commowick at inria.fr (Olivier Commowick) Date: Thu, 2 Feb 2017 11:24:55 +0100 Subject: [ITK-users] Problem with ITK eigensystem In-Reply-To: <779D7A51-94AE-4101-A70B-DEC837408DFC@inria.fr> References: <2444669A-4CBE-4C72-BB82-B3538C4513B1@inria.fr> <242A16CD-79C1-4427-94DB-3AFCD1A33851@inria.fr> <96DC429F-7F78-49D7-A026-930012074F27@inria.fr> <7FE2FD85-C0C9-47BD-AE85-9B6FE5E1ADE6@inria.fr> <779D7A51-94AE-4101-A70B-DEC837408DFC@inria.fr> Message-ID: <918B17E3-0FE0-4A24-B2F1-99F3DEE974CF@inria.fr> Hello all, I have found the bugs, which are tricky. Now my patched version is working on my example. I will submit it to review on gerrit Best Olivier > On 2 Feb 2017, at 10:06, Olivier Commowick wrote: > > Oh, and I remember only now : in fact it might just be that applying the patch I sent in the email solves this problem of infinite loop while still producing nan values > >> On 2 Feb 2017, at 09:27, Olivier Commowick > wrote: >> >> Hi, >> >> Thanks for your test. There might be a bug in my test or the way you ran it since for me it doesn?t take a few minutes but rather less than a second. That being said since it produces nans it might be that on some OS it goes into an infinite loop... >> >> Olivier >> >>> On 2 Feb 2017, at 00:02, D?enan Zuki? > wrote: >>> >>> Hi Olivier, >>> >>> I tried running you example. One thing struck me right away: ITK version is much slower (after a few minutes running in release mod I killed it) than VNL version (about a second in debug mode) for your input. >>> >>> I can't comment the patch content or the numeric stability. Perhaps Brad and Hans can pitch in? >>> >>> Regards, >>> D?enan >>> >>> On Tue, Jan 31, 2017 at 11:24 AM, Olivier Commowick > wrote: >>> Hello, >>> >>> I think I have found a bug in the behaviour of ITK?s symmetric eigensystem. In the attached link (http://olivier.commowick.org/tmp/Test.zip ) you will find an example code and matrix that fails with it and not with VNL?s symmetric eigensystem (run on macOS 10.12, Xcode 8.2.1). >>> >>> It seems to me that there are subtle differences in between ITK and VNL versions, VNL being more robust (and the same as what Matlab gives, I didn?t test python). Here is what I have found so far : >>> >>> - the hypothenuse function (hypot for ITK and pythag for VNL) do not get always the exact same result up to a very far away decimal >>> - some loop indices were wrong I think in the ITK eigensystem. Some do vary in the VNL version, not in ITK?s equivalent >>> >>> In the patch file attached, I have made a set of corrections that make things in ITK eigensystem closer to VNL but still the ITK version fails. I have to say I am getting completely lost here so I am calling upon the community for help. If anyone knows this enough, could you try the test attached and see if you have any ideas of what is going on. That would help us a lot. >>> >>> The test attached can be compiled with cmake and run with the text file included : ./test_eigensystem data.txt >>> >>> Thanks in advance >>> Olivier >>> >>> >>> >>> --- >>> >>> Olivier Commowick, Ph.D. >>> Research Scientist >>> INRIA Rennes - Bretagne Atlantique, VISAGES Team >>> Campus de Beaulieu >>> 35042 Rennes >>> FRANCE >>> >>> Phone: +33 2 99 84 25 92 >>> Email: Olivier.Commowick at inria.fr >>> Web: http://olivier.commowick.org/ >>> >>> >>> -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: itk-eigen.patch Type: application/octet-stream Size: 2829 bytes Desc: not available URL: -------------- next part -------------- An HTML attachment was scrubbed... URL: From cr at neuro.ma.uni-heidelberg.de Fri Feb 3 02:38:24 2017 From: cr at neuro.ma.uni-heidelberg.de (Chr. Rossmanith) Date: Fri, 3 Feb 2017 08:38:24 +0100 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: I have to modify the source code in the tar archive, which I can download from the wiki, not the wiki itself. But I think, I have no access to that tar file. Regards, Christina On 01.02.2017 23:28, Bill Lorensen wrote: > That is correct. Update the wiki version. > > On Feb 1, 2017 5:02 PM, "D?enan Zuki?" > wrote: > > Hi Christina, > > you should not create a pull request for that repository, but > rather modify the example directly on the wiki > . The repository is updated > manually by an automated script which scrapes the wiki. I think > that Bill usually invokes it. > > Regards, > D?enan > > On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin > > > wrote: > > Hello Christina, > > Thank you for the bug report. Could you create an issue and a > pull-request to solve the problem in this repository: > https://github.com/InsightSoftwareConsortium/ITKWikiExamples > > > Thank you! > Francois > > On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith > > wrote: > > Hi, > > I've just downloaded > https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar > > which doesn't compile out of the box because ImageFilter.h > tries to include ImageFilter.txx which does not exist - > should be ImageFilter.hxx (or ImageFilter.hxx must be > renamed to ImageFilter.txx). > > Regards, > > Christina Ro?manith > > _____________________________________ > > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bill.lorensen at gmail.com Fri Feb 3 07:32:04 2017 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 3 Feb 2017 07:32:04 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: Change the wiki file. The archive will be updated overnight.. On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith wrote: > I have to modify the source code in the tar archive, which I can download > from the wiki, not the wiki itself. But I think, I have no access to that > tar file. > > Regards, > Christina > > > On 01.02.2017 23:28, Bill Lorensen wrote: > > That is correct. Update the wiki version. > > On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: > > Hi Christina, > > you should not create a pull request for that repository, but rather modify > the example directly on the wiki. The repository is updated manually by an > automated script which scrapes the wiki. I think that Bill usually invokes > it. > > Regards, > D?enan > > On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin > wrote: >> >> Hello Christina, >> >> Thank you for the bug report. Could you create an issue and a pull-request >> to solve the problem in this repository: >> https://github.com/InsightSoftwareConsortium/ITKWikiExamples >> >> Thank you! >> Francois >> >> On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith >> wrote: >>> >>> Hi, >>> >>> I've just downloaded >>> https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar >>> which doesn't compile out of the box because ImageFilter.h tries to include >>> ImageFilter.txx which does not exist - should be ImageFilter.hxx (or >>> ImageFilter.hxx must be renamed to ImageFilter.txx). >>> >>> Regards, >>> >>> Christina Ro?manith >>> >>> _____________________________________ >> >> >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> > > > -- Unpaid intern in BillsBasement at noware dot com From dzenanz at gmail.com Fri Feb 3 08:42:15 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Fri, 3 Feb 2017 08:42:15 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: Which example are you trying to modify Christina? On Fri, Feb 3, 2017 at 7:32 AM, Bill Lorensen wrote: > Change the wiki file. The archive will be updated overnight.. > > > On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith > wrote: > > I have to modify the source code in the tar archive, which I can download > > from the wiki, not the wiki itself. But I think, I have no access to that > > tar file. > > > > Regards, > > Christina > > > > > > On 01.02.2017 23:28, Bill Lorensen wrote: > > > > That is correct. Update the wiki version. > > > > On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: > > > > Hi Christina, > > > > you should not create a pull request for that repository, but rather > modify > > the example directly on the wiki. The repository is updated manually by > an > > automated script which scrapes the wiki. I think that Bill usually > invokes > > it. > > > > Regards, > > D?enan > > > > On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin < > francois.budin at kitware.com> > > wrote: > >> > >> Hello Christina, > >> > >> Thank you for the bug report. Could you create an issue and a > pull-request > >> to solve the problem in this repository: > >> https://github.com/InsightSoftwareConsortium/ITKWikiExamples > >> > >> Thank you! > >> Francois > >> > >> On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith > >> wrote: > >>> > >>> Hi, > >>> > >>> I've just downloaded > >>> https://github.com/lorensen/ITKWikiExamplesTarballs/raw/ > master/ImageFilter.tar > >>> which doesn't compile out of the box because ImageFilter.h tries to > include > >>> ImageFilter.txx which does not exist - should be ImageFilter.hxx (or > >>> ImageFilter.hxx must be renamed to ImageFilter.txx). > >>> > >>> Regards, > >>> > >>> Christina Ro?manith > >>> > >>> _____________________________________ > >> > >> > >> > >> _____________________________________ > >> 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://public.kitware.com/mailman/listinfo/insight-users > >> > > > > > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > -------------- next part -------------- An HTML attachment was scrubbed... URL: From cr at neuro.ma.uni-heidelberg.de Fri Feb 3 09:40:34 2017 From: cr at neuro.ma.uni-heidelberg.de (Chr. Rossmanith) Date: Fri, 3 Feb 2017 15:40:34 +0100 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> Message-ID: <3c7f0f13-6bd9-6f7c-f32e-aeb52a6e23f4@neuro.ma.uni-heidelberg.de> Currently ImageFilter.h in the wiki includes ImageFilter.hxx but ImageFilter.h from the tar archive includes ImageFilter.txx - that makes it difficult for me to believe that the tar archive is created from the wiki content. Regards Christina On 03.02.2017 13:32, Bill Lorensen wrote: > Change the wiki file. The archive will be updated overnight.. > > > On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith > wrote: >> I have to modify the source code in the tar archive, which I can download >> from the wiki, not the wiki itself. But I think, I have no access to that >> tar file. >> >> Regards, >> Christina >> >> >> On 01.02.2017 23:28, Bill Lorensen wrote: >> >> That is correct. Update the wiki version. >> >> On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: >> >> Hi Christina, >> >> you should not create a pull request for that repository, but rather modify >> the example directly on the wiki. The repository is updated manually by an >> automated script which scrapes the wiki. I think that Bill usually invokes >> it. >> >> Regards, >> D?enan >> >> On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin >> wrote: >>> Hello Christina, >>> >>> Thank you for the bug report. Could you create an issue and a pull-request >>> to solve the problem in this repository: >>> https://github.com/InsightSoftwareConsortium/ITKWikiExamples >>> >>> Thank you! >>> Francois >>> >>> On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith >>> wrote: >>>> Hi, >>>> >>>> I've just downloaded >>>> https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar >>>> which doesn't compile out of the box because ImageFilter.h tries to include >>>> ImageFilter.txx which does not exist - should be ImageFilter.hxx (or >>>> ImageFilter.hxx must be renamed to ImageFilter.txx). >>>> >>>> Regards, >>>> >>>> Christina Ro?manith >>>> >>>> _____________________________________ >>> >>> >>> _____________________________________ >>> 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://public.kitware.com/mailman/listinfo/insight-users >>> >> >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dzenanz at gmail.com Fri Feb 3 09:45:45 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Fri, 3 Feb 2017 09:45:45 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: <3c7f0f13-6bd9-6f7c-f32e-aeb52a6e23f4@neuro.ma.uni-heidelberg.de> References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> <3c7f0f13-6bd9-6f7c-f32e-aeb52a6e23f4@neuro.ma.uni-heidelberg.de> Message-ID: Hi Bill, was the file structure in the git repo created manually? Or a better question: is the file structure in git repo updated automatically when file names on the wiki are changed? File content does seem to be updated. Regards, D?enan On Fri, Feb 3, 2017 at 9:40 AM, Chr. Rossmanith < cr at neuro.ma.uni-heidelberg.de> wrote: > Currently ImageFilter.h in the wiki > > includes ImageFilter.hxx but ImageFilter.h from the tar archive includes > ImageFilter.txx - that makes it difficult for me to believe that the tar > archive is created from the wiki content. > > Regards > Christina > > > On 03.02.2017 13:32, Bill Lorensen wrote: > > Change the wiki file. The archive will be updated overnight.. > > > On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith wrote: > > I have to modify the source code in the tar archive, which I can download > from the wiki, not the wiki itself. But I think, I have no access to that > tar file. > > Regards, > Christina > > > On 01.02.2017 23:28, Bill Lorensen wrote: > > That is correct. Update the wiki version. > > On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: > > Hi Christina, > > you should not create a pull request for that repository, but rather modify > the example directly on the wiki. The repository is updated manually by an > automated script which scrapes the wiki. I think that Bill usually invokes > it. > > Regards, > D?enan > > On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin > wrote: > > Hello Christina, > > Thank you for the bug report. Could you create an issue and a pull-request > to solve the problem in this repository:https://github.com/InsightSoftwareConsortium/ITKWikiExamples > > Thank you! > Francois > > On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith wrote: > > Hi, > > I've just downloadedhttps://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar > which doesn't compile out of the box because ImageFilter.h tries to include > ImageFilter.txx which does not exist - should be ImageFilter.hxx (or > ImageFilter.hxx must be renamed to ImageFilter.txx). > > Regards, > > Christina Ro?manith > > _____________________________________ > > > > _____________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects athttp://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://public.kitware.com/mailman/listinfo/insight-users > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bill.lorensen at gmail.com Fri Feb 3 10:01:38 2017 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 3 Feb 2017 10:01:38 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> <3c7f0f13-6bd9-6f7c-f32e-aeb52a6e23f4@neuro.ma.uni-heidelberg.de> Message-ID: It should change when the wiki is changed. I'll look into this. On Fri, Feb 3, 2017 at 9:45 AM, D?enan Zuki? wrote: > Hi Bill, > > was the file structure in the git repo created manually? Or a better > question: is the file structure in git repo updated automatically when file > names on the wiki are changed? File content does seem to be updated. > > Regards, > D?enan > > On Fri, Feb 3, 2017 at 9:40 AM, Chr. Rossmanith > wrote: >> >> Currently ImageFilter.h in the wiki includes ImageFilter.hxx but >> ImageFilter.h from the tar archive includes ImageFilter.txx - that makes it >> difficult for me to believe that the tar archive is created from the wiki >> content. >> >> Regards >> Christina >> >> >> On 03.02.2017 13:32, Bill Lorensen wrote: >> >> Change the wiki file. The archive will be updated overnight.. >> >> >> On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith >> wrote: >> >> I have to modify the source code in the tar archive, which I can download >> from the wiki, not the wiki itself. But I think, I have no access to that >> tar file. >> >> Regards, >> Christina >> >> >> On 01.02.2017 23:28, Bill Lorensen wrote: >> >> That is correct. Update the wiki version. >> >> On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: >> >> Hi Christina, >> >> you should not create a pull request for that repository, but rather >> modify >> the example directly on the wiki. The repository is updated manually by an >> automated script which scrapes the wiki. I think that Bill usually invokes >> it. >> >> Regards, >> D?enan >> >> On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin >> >> wrote: >> >> Hello Christina, >> >> Thank you for the bug report. Could you create an issue and a pull-request >> to solve the problem in this repository: >> https://github.com/InsightSoftwareConsortium/ITKWikiExamples >> >> Thank you! >> Francois >> >> On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith >> wrote: >> >> Hi, >> >> I've just downloaded >> >> https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar >> which doesn't compile out of the box because ImageFilter.h tries to >> include >> ImageFilter.txx which does not exist - should be ImageFilter.hxx (or >> ImageFilter.hxx must be renamed to ImageFilter.txx). >> >> Regards, >> >> Christina Ro?manith >> >> _____________________________________ >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> >> >> >> > -- Unpaid intern in BillsBasement at noware dot com From bill.lorensen at gmail.com Fri Feb 3 10:25:04 2017 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 3 Feb 2017 10:25:04 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> <3c7f0f13-6bd9-6f7c-f32e-aeb52a6e23f4@neuro.ma.uni-heidelberg.de> Message-ID: For some reason the tar file is not being updated by the nightly sync script.. I'll check onto it. On Fri, Feb 3, 2017 at 10:01 AM, Bill Lorensen wrote: > It should change when the wiki is changed. I'll look into this. > > > On Fri, Feb 3, 2017 at 9:45 AM, D?enan Zuki? wrote: >> Hi Bill, >> >> was the file structure in the git repo created manually? Or a better >> question: is the file structure in git repo updated automatically when file >> names on the wiki are changed? File content does seem to be updated. >> >> Regards, >> D?enan >> >> On Fri, Feb 3, 2017 at 9:40 AM, Chr. Rossmanith >> wrote: >>> >>> Currently ImageFilter.h in the wiki includes ImageFilter.hxx but >>> ImageFilter.h from the tar archive includes ImageFilter.txx - that makes it >>> difficult for me to believe that the tar archive is created from the wiki >>> content. >>> >>> Regards >>> Christina >>> >>> >>> On 03.02.2017 13:32, Bill Lorensen wrote: >>> >>> Change the wiki file. The archive will be updated overnight.. >>> >>> >>> On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith >>> wrote: >>> >>> I have to modify the source code in the tar archive, which I can download >>> from the wiki, not the wiki itself. But I think, I have no access to that >>> tar file. >>> >>> Regards, >>> Christina >>> >>> >>> On 01.02.2017 23:28, Bill Lorensen wrote: >>> >>> That is correct. Update the wiki version. >>> >>> On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: >>> >>> Hi Christina, >>> >>> you should not create a pull request for that repository, but rather >>> modify >>> the example directly on the wiki. The repository is updated manually by an >>> automated script which scrapes the wiki. I think that Bill usually invokes >>> it. >>> >>> Regards, >>> D?enan >>> >>> On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin >>> >>> wrote: >>> >>> Hello Christina, >>> >>> Thank you for the bug report. Could you create an issue and a pull-request >>> to solve the problem in this repository: >>> https://github.com/InsightSoftwareConsortium/ITKWikiExamples >>> >>> Thank you! >>> Francois >>> >>> On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith >>> wrote: >>> >>> Hi, >>> >>> I've just downloaded >>> >>> https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar >>> which doesn't compile out of the box because ImageFilter.h tries to >>> include >>> ImageFilter.txx which does not exist - should be ImageFilter.hxx (or >>> ImageFilter.hxx must be renamed to ImageFilter.txx). >>> >>> Regards, >>> >>> Christina Ro?manith >>> >>> _____________________________________ >>> >>> _____________________________________ >>> 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://public.kitware.com/mailman/listinfo/insight-users >>> >>> >>> >>> >> > > > > -- > Unpaid intern in BillsBasement at noware dot com -- Unpaid intern in BillsBasement at noware dot com From bill.lorensen at gmail.com Fri Feb 3 12:11:33 2017 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 3 Feb 2017 12:11:33 -0500 Subject: [ITK-users] Bug in example ImageFilter In-Reply-To: References: <089fe6fa-d9c7-616b-8723-c64184a66049@neuro.ma.uni-heidelberg.de> <3c7f0f13-6bd9-6f7c-f32e-aeb52a6e23f4@neuro.ma.uni-heidelberg.de> Message-ID: i found the problem. twi examples in the sane directory had a ImageFilter.h file. I have fixed the offending example and all should be OK now. Thanks for reporting the problem. Bill On Fri, Feb 3, 2017 at 10:25 AM, Bill Lorensen wrote: > For some reason the tar file is not being updated by the nightly sync > script.. I'll check onto it. > > > On Fri, Feb 3, 2017 at 10:01 AM, Bill Lorensen wrote: >> It should change when the wiki is changed. I'll look into this. >> >> >> On Fri, Feb 3, 2017 at 9:45 AM, D?enan Zuki? wrote: >>> Hi Bill, >>> >>> was the file structure in the git repo created manually? Or a better >>> question: is the file structure in git repo updated automatically when file >>> names on the wiki are changed? File content does seem to be updated. >>> >>> Regards, >>> D?enan >>> >>> On Fri, Feb 3, 2017 at 9:40 AM, Chr. Rossmanith >>> wrote: >>>> >>>> Currently ImageFilter.h in the wiki includes ImageFilter.hxx but >>>> ImageFilter.h from the tar archive includes ImageFilter.txx - that makes it >>>> difficult for me to believe that the tar archive is created from the wiki >>>> content. >>>> >>>> Regards >>>> Christina >>>> >>>> >>>> On 03.02.2017 13:32, Bill Lorensen wrote: >>>> >>>> Change the wiki file. The archive will be updated overnight.. >>>> >>>> >>>> On Fri, Feb 3, 2017 at 2:38 AM, Chr. Rossmanith >>>> wrote: >>>> >>>> I have to modify the source code in the tar archive, which I can download >>>> from the wiki, not the wiki itself. But I think, I have no access to that >>>> tar file. >>>> >>>> Regards, >>>> Christina >>>> >>>> >>>> On 01.02.2017 23:28, Bill Lorensen wrote: >>>> >>>> That is correct. Update the wiki version. >>>> >>>> On Feb 1, 2017 5:02 PM, "D?enan Zuki?" wrote: >>>> >>>> Hi Christina, >>>> >>>> you should not create a pull request for that repository, but rather >>>> modify >>>> the example directly on the wiki. The repository is updated manually by an >>>> automated script which scrapes the wiki. I think that Bill usually invokes >>>> it. >>>> >>>> Regards, >>>> D?enan >>>> >>>> On Wed, Feb 1, 2017 at 11:13 AM, Francois Budin >>>> >>>> wrote: >>>> >>>> Hello Christina, >>>> >>>> Thank you for the bug report. Could you create an issue and a pull-request >>>> to solve the problem in this repository: >>>> https://github.com/InsightSoftwareConsortium/ITKWikiExamples >>>> >>>> Thank you! >>>> Francois >>>> >>>> On Wed, Feb 1, 2017 at 7:03 AM, Chr. Rossmanith >>>> wrote: >>>> >>>> Hi, >>>> >>>> I've just downloaded >>>> >>>> https://github.com/lorensen/ITKWikiExamplesTarballs/raw/master/ImageFilter.tar >>>> which doesn't compile out of the box because ImageFilter.h tries to >>>> include >>>> ImageFilter.txx which does not exist - should be ImageFilter.hxx (or >>>> ImageFilter.hxx must be renamed to ImageFilter.txx). >>>> >>>> Regards, >>>> >>>> Christina Ro?manith >>>> >>>> _____________________________________ >>>> >>>> _____________________________________ >>>> 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://public.kitware.com/mailman/listinfo/insight-users >>>> >>>> >>>> >>>> >>> >> >> >> >> -- >> Unpaid intern in BillsBasement at noware dot com > > > > -- > Unpaid intern in BillsBasement at noware dot com -- Unpaid intern in BillsBasement at noware dot com From 10811130d at gmail.com Fri Feb 3 23:50:21 2017 From: 10811130d at gmail.com (jiancong wang) Date: Fri, 3 Feb 2017 23:50:21 -0500 Subject: [ITK-users] Questions on the itkANTSNeighborhoodCorrelationImageToImageMetricv4GetValueAndDerivativeThreader.hxx Message-ID: Hi guys, I am working on replicating this image registration metric on gpu and has some questions that I want to ask. In both of the UpdateQueue functions I saw a line like this: ...... for ( SizeValueType indct = i; indct < hoodlen; indct += ( diameter + NumericTraits::OneValue() ) ) ...... Why the index is incremented by the diameter of the NCC window instead of by 1? Isn't this suppose accumulate local pixel values for reuse purpose? Also why there is only one for loop here? How do they handle 3D data in this case? I read the original paper and they are trying to cache the local sum value (for example for a 7 by 7 window they are supposed to accumulate 7by1 column window, that each time it proceeds it only has to recompute the next 7by1 column instead of the full 7by7 window). Any help is greatly appreciated! Thanks! -------------- next part -------------- An HTML attachment was scrubbed... URL: From bakkari.abdelkhalek at hotmail.fr Sat Feb 4 13:28:11 2017 From: bakkari.abdelkhalek at hotmail.fr (Abdelkhalek Bakkari) Date: Sat, 4 Feb 2017 18:28:11 +0000 Subject: [ITK-users] Binary Fill hole Image Filter for 3D Image In-Reply-To: References: , Message-ID: Dear ITK-users, I tried to adopt the BinaryFillholeImageFilter for 3D image (contour.mha). Unfortunately, the result which I obtained is not what I expect. The fragment of code which I used is : // Lecture of the contour.mha typedef itk::Image< unsigned char, 3 > UCharImageType; typedef itk::ImageFileReader ImageReaderType; ImageReaderType::Pointer reader = ImageReaderType::New(); reader->SetFileName("contour.mha"); reader->Update(); // Binary Fill Hole Image Filter typedef itk::BinaryFillholeImageFilter< UCharImageType > FilterType; FilterType::Pointer filter = FilterType::New(); filter->SetInput( reader->GetOutput() ); filter->SetForegroundValue( itk::NumericTraits< unsigned char >::min() ); filter->Update(); // Save the BinaryFillHoleImage { typedef itk::ImageFileWriter ImageWriterType; ImageWriterType::Pointer writer = ImageWriterType::New(); writer->SetFileName("BinaryFillHoleImage.mha"); writer->SetInput(filter->GetOutput()); try{ writer->Update(); }catch(itk::ExceptionObject &e){ std::cerr << e << std::endl; } } Thank you in advance. Kind regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: contour.rar Type: application/octet-stream Size: 59299 bytes Desc: contour.rar URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: BinaryFillHoleImage.rar Type: application/octet-stream Size: 59311 bytes Desc: BinaryFillHoleImage.rar URL: From dzenanz at gmail.com Sat Feb 4 13:37:14 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Sat, 4 Feb 2017 13:37:14 -0500 Subject: [ITK-users] Questions on the itkANTSNeighborhoodCorrelationImageToImageMetricv4GetValueAndDerivativeThreader.hxx In-Reply-To: References: Message-ID: Hi Jiancong, I have not seen this class before, so I can't answer your questions. However I can recommend you to run itkANTSNeighborhoodCorrelationImageToImageMetricv4Test.cxx under debugger and inspect the loop of interest. Then change ImageDimension to 3 and run it again. It looks like the test was written with such experimentation in mind, so it should run. You might also play with imageSize (currently 6) to have a smaller or large image. Hopefully this will help you to understand how that code works. Regards On Fri, Feb 3, 2017 at 11:50 PM, jiancong wang <10811130d at gmail.com> wrote: > Hi guys, > I am working on replicating this image registration metric on gpu and has > some questions that I want to ask. > > In both of the UpdateQueue functions I saw a line like this: > ...... > for ( SizeValueType indct = i; indct < hoodlen; indct += ( diameter + > NumericTraits::OneValue() ) ) > ...... > > Why the index is incremented by the diameter of the NCC window instead of > by 1? Isn't this suppose accumulate local pixel values for reuse purpose? > Also why there is only one for loop here? How do they handle 3D data in > this case? > > I read the original paper and they are trying to cache the local sum value > (for example for a 7 by 7 window they are supposed to accumulate 7by1 > column window, that each time it proceeds it only has to recompute the next > 7by1 column instead of the full 7by7 window). > > Any help is greatly appreciated! Thanks! > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dzenanz at gmail.com Sat Feb 4 14:03:09 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Sat, 4 Feb 2017 14:03:09 -0500 Subject: [ITK-users] Binary Fill hole Image Filter for 3D Image In-Reply-To: References: Message-ID: Hi Abdelkhalek, your image does not have any holes! The input and output images are binary identical (examined using file compare tool). If I modify your input image to also contain a real hole (not connected to image edge or the background), it gets filled properly. See attached. Regards, D?enan On Sat, Feb 4, 2017 at 1:28 PM, Abdelkhalek Bakkari < bakkari.abdelkhalek at hotmail.fr> wrote: > > > > > Dear ITK-users, > > I tried to adopt the BinaryFillholeImageFilter for 3D image (contour.mha). > Unfortunately, the result which I obtained is not what I expect. > > The fragment of code which I used is : > > // Lecture of the > contour.mha > typedef itk::Image< > unsigned char, 3 > UCharImageType; > typedef > itk::ImageFileReader ImageReaderType; > ImageReaderType::Pointer reader = > ImageReaderType::New(); > reader->SetFileName("contour. > mha"); > reader->Update(); > > // Binary Fill Hole Image > Filter > typedef itk::BinaryFillholeImageFilter< > UCharImageType > FilterType; > FilterType::Pointer filter = FilterType::New(); > filter->SetInput( reader->GetOutput() ); > filter->SetForegroundValue( itk::NumericTraits< unsigned char >::min() ); > filter->Update(); > // Save the > BinaryFillHoleImage > { > typedef itk::ImageFileWriter ImageWriterType; > ImageWriterType::Pointer writer = ImageWriterType::New(); > writer->SetFileName("BinaryFillHoleImage.mha"); > writer->SetInput(filter->GetOutput()); > try{ > writer->Update(); > }catch(itk::ExceptionObject &e){ > std::cerr << e << std::endl; > } > } > > > > Thank you in advance. > > Kind regards, > > > Abdelkhalek Bakkari > Ph.D candidate in Computer Science > Institute of Applied Computer Science > Lodz University of Technology, Poland > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot 2017-02-04 13.57.26.png Type: image/png Size: 21085 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Images.7z Type: application/octet-stream Size: 64129 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: tester.cpp Type: text/x-c++src Size: 1235 bytes Desc: not available URL: From dzenanz at gmail.com Sat Feb 4 14:46:25 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Sat, 4 Feb 2017 14:46:25 -0500 Subject: [ITK-users] Binary Fill hole Image Filter for 3D Image In-Reply-To: References: Message-ID: Hi Abdelkhalek, try using binary opening/closing , which are implemented as binary dilation and erosion. https://itk.org/Doxygen/html/group__MathematicalMorphologyImageFilters.html Regards, D?enan On Sat, Feb 4, 2017 at 2:43 PM, Abdelkhalek Bakkari < bakkari.abdelkhalek at hotmail.fr> wrote: > Hi Dzenan, > > > My goal is to obtain the big contour of the 3D image. For this reason, I > tried to use Binary Fill hole Image Filter and after the > BinaryContourImageFilter. > > Could you provide me another way using ITK, please? > > > Best regards, > > > > > ------------------------------ > *From:* D?enan Zuki? > *Sent:* 04 February 2017 20:03 > *To:* Abdelkhalek Bakkari > *Cc:* insight-users > *Subject:* Re: Binary Fill hole Image Filter for 3D Image > > Hi Abdelkhalek, > > your image does not have any holes! The input and output images are binary > identical (examined using file compare tool). If I modify your input image > to also contain a real hole (not connected to image edge or the > background), it gets filled properly. See attached. > > Regards, > D?enan > > On Sat, Feb 4, 2017 at 1:28 PM, Abdelkhalek Bakkari < > bakkari.abdelkhalek at hotmail.fr> wrote: > >> >> >> >> >> Dear ITK-users, >> >> I tried to adopt the BinaryFillholeImageFilter for 3D image (contour.mha). >> Unfortunately, the result which I obtained is not what I expect. >> >> The fragment of code which I used is : >> >> // Lecture of the >> contour.mha >> typedef itk::Image< >> unsigned char, 3 > UCharImageType; >> typedef >> itk::ImageFileReader ImageReaderType; >> ImageReaderType::Pointer reader = >> ImageReaderType::New(); >> reader->SetFileName("contour.m >> ha"); >> reader->Update(); >> >> // Binary Fill Hole Image >> Filter >> typedef >> itk::BinaryFillholeImageFilter< UCharImageType > FilterType; >> FilterType::Pointer filter = FilterType::New(); >> filter->SetInput( reader->GetOutput() ); >> filter->SetForegroundValue( itk::NumericTraits< unsigned char >::min() ); >> filter->Update(); >> // Save the >> BinaryFillHoleImage >> { >> typedef itk::ImageFileWriter ImageWriterType; >> ImageWriterType::Pointer writer = ImageWriterType::New(); >> writer->SetFileName("BinaryFillHoleImage.mha"); >> writer->SetInput(filter->GetOutput()); >> try{ >> writer->Update(); >> }catch(itk::ExceptionObject &e){ >> std::cerr << e << std::endl; >> } >> } >> >> >> >> Thank you in advance. >> >> Kind regards, >> >> >> Abdelkhalek Bakkari >> Ph.D candidate in Computer Science >> Institute of Applied Computer Science >> Lodz University of Technology, Poland >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bakkari.abdelkhalek at hotmail.fr Sat Feb 4 14:43:07 2017 From: bakkari.abdelkhalek at hotmail.fr (Abdelkhalek Bakkari) Date: Sat, 4 Feb 2017 19:43:07 +0000 Subject: [ITK-users] Binary Fill hole Image Filter for 3D Image In-Reply-To: References: , Message-ID: Hi Dzenan, My goal is to obtain the big contour of the 3D image. For this reason, I tried to use Binary Fill hole Image Filter and after the BinaryContourImageFilter. Could you provide me another way using ITK, please? Best regards, ________________________________ From: D?enan Zuki? Sent: 04 February 2017 20:03 To: Abdelkhalek Bakkari Cc: insight-users Subject: Re: Binary Fill hole Image Filter for 3D Image Hi Abdelkhalek, your image does not have any holes! The input and output images are binary identical (examined using file compare tool). If I modify your input image to also contain a real hole (not connected to image edge or the background), it gets filled properly. See attached. Regards, D?enan On Sat, Feb 4, 2017 at 1:28 PM, Abdelkhalek Bakkari > wrote: Dear ITK-users, I tried to adopt the BinaryFillholeImageFilter for 3D image (contour.mha). Unfortunately, the result which I obtained is not what I expect. The fragment of code which I used is : // Lecture of the contour.mha typedef itk::Image< unsigned char, 3 > UCharImageType; typedef itk::ImageFileReader ImageReaderType; ImageReaderType::Pointer reader = ImageReaderType::New(); reader->SetFileName("contour.mha"); reader->Update(); // Binary Fill Hole Image Filter typedef itk::BinaryFillholeImageFilter< UCharImageType > FilterType; FilterType::Pointer filter = FilterType::New(); filter->SetInput( reader->GetOutput() ); filter->SetForegroundValue( itk::NumericTraits< unsigned char >::min() ); filter->Update(); // Save the BinaryFillHoleImage { typedef itk::ImageFileWriter ImageWriterType; ImageWriterType::Pointer writer = ImageWriterType::New(); writer->SetFileName("BinaryFillHoleImage.mha"); writer->SetInput(filter->GetOutput()); try{ writer->Update(); }catch(itk::ExceptionObject &e){ std::cerr << e << std::endl; } } Thank you in advance. Kind regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland -------------- next part -------------- An HTML attachment was scrubbed... URL: From bakkari.abdelkhalek at hotmail.fr Tue Feb 7 06:29:48 2017 From: bakkari.abdelkhalek at hotmail.fr (Abdelkhalek Bakkari) Date: Tue, 7 Feb 2017 11:29:48 +0000 Subject: [ITK-users] Binary Contour Detection for 3D Image using ITK - Thickness - Message-ID: Dear ITK users, After using the BinaryFillHoleFilter for a 3D Dicom image (see attached), I adopted the BinaryContourImageFilter in order to obtain the contour of the image. However, the thikness of the contour is very big. My goal is to obtain 1 pixel of thickness. The fragment of my code is : ------------------------------------------------------ #include "itkImage.h" #include "itkImageFileReader.h" #include "itkImageFileWriter.h" #include "itkRescaleIntensityImageFilter.h" #include "itkCastImageFilter.h" #include "itkCannyEdgeDetectionImageFilter.h" #include #include #include #include #include #include #include int main(int argc, char **argv) { const unsigned int Dimension = 3; typedef unsigned char InputPixelType; typedef unsigned char OutputPixelType; typedef itk::Image InputImageType; typedef itk::Image OutputImageType; typedef itk::ImageFileReader< InputImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileName("BinaryFillHoleImage.mha"); reader->Update(); //Slice by Slice Binary Contour // Binary Contour Filter typedef itk::BinaryContourImageFilter binaryContourImageFilterType; binaryContourImageFilterType::Pointer binaryContourFilter = binaryContourImageFilterType::New (); binaryContourFilter->SetInput(reader->GetOutput()); binaryContourFilter->SetFullyConnected(1); // true makes thicker contours binaryContourFilter->SetBackgroundValue(0); binaryContourFilter->SetForegroundValue(255); // the value of your binary mask binaryContourFilter->Update(); typedef itk::RescaleIntensityImageFilter< InputImageType, InputImageType > RescaleType; RescaleType::Pointer rescaler = RescaleType::New(); rescaler->SetInput( binaryContourFilter->GetOutput() ); rescaler->SetOutputMinimum( 0 ); rescaler->SetOutputMaximum( 255 ); typedef itk::CastImageFilter< InputImageType, OutputImageType > FilterType; FilterType::Pointer filter = FilterType::New(); filter->SetInput( rescaler->GetOutput() ); // Save the contour { typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName("Cannybinarycontour.mha"); writer->SetInput(filter->GetOutput()); try{ writer->Update(); } catch(itk::ExceptionObject &e) { std::cerr << e << std::endl; } } return EXIT_SUCCESS; } ------------------------------------------------------ Thank you in advance. Best regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: BinaryFillHoleImage.rar Type: application/octet-stream Size: 44079 bytes Desc: BinaryFillHoleImage.rar URL: From dzenanz at gmail.com Tue Feb 7 07:46:49 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Tue, 7 Feb 2017 07:46:49 -0500 Subject: [ITK-users] Binary Contour Detection for 3D Image using ITK - Thickness - In-Reply-To: References: Message-ID: Try SetUsePixelSpacingOff. On Feb 7, 2017 06:30, "Abdelkhalek Bakkari" wrote: > Dear ITK users, > > > After using the BinaryFillHoleFilter for a 3D Dicom image (see attached), > I adopted the BinaryContourImageFilter in order to obtain the contour of > the image. However, the thikness of the contour is very big. My goal is to > obtain 1 pixel of thickness. > > > The fragment of my code is : > > > ------------------------------------------------------ > > #include "itkImage.h" > #include "itkImageFileReader.h" > #include "itkImageFileWriter.h" > #include "itkRescaleIntensityImageFilter.h" > #include "itkCastImageFilter.h" > #include "itkCannyEdgeDetectionImageFilter.h" > #include > #include > #include > #include > #include > #include > #include > > int main(int argc, char **argv) > { > > const unsigned int Dimension = 3; > typedef unsigned char InputPixelType; > typedef unsigned char OutputPixelType; > > typedef itk::Image InputImageType; > typedef itk::Image OutputImageType; > > typedef itk::ImageFileReader< InputImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileName("BinaryFillHoleImage.mha"); > reader->Update(); > > //Slice by Slice Binary Contour > // Binary Contour Filter > typedef itk::BinaryContourImageFilter > binaryContourImageFilterType; > > binaryContourImageFilterType::Pointer binaryContourFilter = > binaryContourImageFilterType::New (); > binaryContourFilter->SetInput(reader->GetOutput()); > binaryContourFilter->SetFullyConnected(1); // true makes thicker contours > binaryContourFilter->SetBackgroundValue(0); > binaryContourFilter->SetForegroundValue(255); // the value of your binary > mask > binaryContourFilter->Update(); > > typedef itk::RescaleIntensityImageFilter< InputImageType, InputImageType > > RescaleType; > RescaleType::Pointer rescaler = RescaleType::New(); > rescaler->SetInput( binaryContourFilter->GetOutput() ); > rescaler->SetOutputMinimum( 0 ); > rescaler->SetOutputMaximum( 255 ); > > typedef itk::CastImageFilter< InputImageType, OutputImageType > FilterType; > FilterType::Pointer filter = FilterType::New(); > filter->SetInput( rescaler->GetOutput() ); > > // Save the contour > { > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName("Cannybinarycontour.mha"); > writer->SetInput(filter->GetOutput()); > > try{ > writer->Update(); > } > catch(itk::ExceptionObject &e) > { > std::cerr << e << std::endl; > } > } > > return EXIT_SUCCESS; > } > > ------------------------------------------------------ > > Thank you in advance. > > > Best regards, > > > Abdelkhalek Bakkari > Ph.D candidate in Computer Science > Institute of Applied Computer Science > Lodz University of Technology, Poland > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bakkari.abdelkhalek at hotmail.fr Tue Feb 7 08:33:41 2017 From: bakkari.abdelkhalek at hotmail.fr (Abdelkhalek Bakkari) Date: Tue, 7 Feb 2017 13:33:41 +0000 Subject: [ITK-users] Binary Contour Detection for 3D Image using ITK - Thickness - In-Reply-To: References: , Message-ID: I am sorry but i did not find the SetUsePixelSpacingOff. Could you explain to me the way of using it. Also, what actually does it mean to turn off the spacing between slices and slice pixel and how is it related to contour generation . Kind regards, Sent from my iPhone On 7 Feb 2017, at 13:46, D?enan Zuki? > wrote: Try SetUsePixelSpacingOff. On Feb 7, 2017 06:30, "Abdelkhalek Bakkari" > wrote: Dear ITK users, After using the BinaryFillHoleFilter for a 3D Dicom image (see attached), I adopted the BinaryContourImageFilter in order to obtain the contour of the image. However, the thikness of the contour is very big. My goal is to obtain 1 pixel of thickness. The fragment of my code is : ------------------------------------------------------ #include "itkImage.h" #include "itkImageFileReader.h" #include "itkImageFileWriter.h" #include "itkRescaleIntensityImageFilter.h" #include "itkCastImageFilter.h" #include "itkCannyEdgeDetectionImageFilter.h" #include #include #include #include #include #include #include int main(int argc, char **argv) { const unsigned int Dimension = 3; typedef unsigned char InputPixelType; typedef unsigned char OutputPixelType; typedef itk::Image InputImageType; typedef itk::Image OutputImageType; typedef itk::ImageFileReader< InputImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileName("BinaryFillHoleImage.mha"); reader->Update(); //Slice by Slice Binary Contour // Binary Contour Filter typedef itk::BinaryContourImageFilter binaryContourImageFilterType; binaryContourImageFilterType::Pointer binaryContourFilter = binaryContourImageFilterType::New (); binaryContourFilter->SetInput(reader->GetOutput()); binaryContourFilter->SetFullyConnected(1); // true makes thicker contours binaryContourFilter->SetBackgroundValue(0); binaryContourFilter->SetForegroundValue(255); // the value of your binary mask binaryContourFilter->Update(); typedef itk::RescaleIntensityImageFilter< InputImageType, InputImageType > RescaleType; RescaleType::Pointer rescaler = RescaleType::New(); rescaler->SetInput( binaryContourFilter->GetOutput() ); rescaler->SetOutputMinimum( 0 ); rescaler->SetOutputMaximum( 255 ); typedef itk::CastImageFilter< InputImageType, OutputImageType > FilterType; FilterType::Pointer filter = FilterType::New(); filter->SetInput( rescaler->GetOutput() ); // Save the contour { typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName("Cannybinarycontour.mha"); writer->SetInput(filter->GetOutput()); try{ writer->Update(); } catch(itk::ExceptionObject &e) { std::cerr << e << std::endl; } } return EXIT_SUCCESS; } ------------------------------------------------------ Thank you in advance. Best regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland -------------- next part -------------- An HTML attachment was scrubbed... URL: From blowekamp at mail.nih.gov Tue Feb 7 08:52:41 2017 From: blowekamp at mail.nih.gov (Lowekamp, Bradley (NIH/NLM/LHC) [C]) Date: Tue, 7 Feb 2017 13:52:41 +0000 Subject: [ITK-users] [ITK] Binary Contour Detection for 3D Image using ITK - Thickness - In-Reply-To: References: Message-ID: <9E696551-65FF-4702-9A12-F685C8174AA6@mail.nih.gov> Hello, I believe that the BinaryCountourImageFilter operates in voxel space so the pixel spacing would not have an effect. I think you are using the wrong metric to determine if the contour is ?1 pixel thick?. You need to remember that you are dealing with a 3D space where the contour is a 2-manifold in the 3-d space. That is to say your ?contour" has 2 dimensions of thickness and 1 dimension that only 1 pixel thick. If you have planar edges this can result in large areas that are solid contours. Please look at the results of ?unexpected? contours in the xy-plane xz-plane _and_ yz_ plane to understand the geometry. Alternatively, if the requirement is to have each slice look like a 1-d contour you can run contour filter in the SliceBySliceImageFitler[1]. However, this will omit the edges that are between slices. HTH, Brad [1] https://itk.org/Doxygen/html/classitk_1_1SliceBySliceImageFilter.html On Feb 7, 2017, at 8:33 AM, Abdelkhalek Bakkari > wrote: I am sorry but i did not find the SetUsePixelSpacingOff. Could you explain to me the way of using it. Also, what actually does it mean to turn off the spacing between slices and slice pixel and how is it related to contour generation . Kind regards, Sent from my iPhone On 7 Feb 2017, at 13:46, D?enan Zuki? > wrote: Try SetUsePixelSpacingOff. On Feb 7, 2017 06:30, "Abdelkhalek Bakkari" > wrote: Dear ITK users, After using the BinaryFillHoleFilter for a 3D Dicom image (see attached), I adopted the BinaryContourImageFilter in order to obtain the contour of the image. However, the thikness of the contour is very big. My goal is to obtain 1 pixel of thickness. The fragment of my code is : ------------------------------------------------------ #include "itkImage.h" #include "itkImageFileReader.h" #include "itkImageFileWriter.h" #include "itkRescaleIntensityImageFilter.h" #include "itkCastImageFilter.h" #include "itkCannyEdgeDetectionImageFilter.h" #include #include #include #include #include #include #include int main(int argc, char **argv) { const unsigned int Dimension = 3; typedef unsigned char InputPixelType; typedef unsigned char OutputPixelType; typedef itk::Image InputImageType; typedef itk::Image OutputImageType; typedef itk::ImageFileReader< InputImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileName("BinaryFillHoleImage.mha"); reader->Update(); //Slice by Slice Binary Contour // Binary Contour Filter typedef itk::BinaryContourImageFilter binaryContourImageFilterType; binaryContourImageFilterType::Pointer binaryContourFilter = binaryContourImageFilterType::New (); binaryContourFilter->SetInput(reader->GetOutput()); binaryContourFilter->SetFullyConnected(1); // true makes thicker contours binaryContourFilter->SetBackgroundValue(0); binaryContourFilter->SetForegroundValue(255); // the value of your binary mask binaryContourFilter->Update(); typedef itk::RescaleIntensityImageFilter< InputImageType, InputImageType > RescaleType; RescaleType::Pointer rescaler = RescaleType::New(); rescaler->SetInput( binaryContourFilter->GetOutput() ); rescaler->SetOutputMinimum( 0 ); rescaler->SetOutputMaximum( 255 ); typedef itk::CastImageFilter< InputImageType, OutputImageType > FilterType; FilterType::Pointer filter = FilterType::New(); filter->SetInput( rescaler->GetOutput() ); // Save the contour { typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName("Cannybinarycontour.mha"); writer->SetInput(filter->GetOutput()); try{ writer->Update(); } catch(itk::ExceptionObject &e) { std::cerr << e << std::endl; } } return EXIT_SUCCESS; } ------------------------------------------------------ Thank you in advance. Best regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland _____________________________________ 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://public.kitware.com/mailman/listinfo/insight-users _______________________________________________ Community mailing list Community at itk.org http://public.kitware.com/mailman/listinfo/community -------------- next part -------------- An HTML attachment was scrubbed... URL: From pe3ak at yahoo.com Tue Feb 7 15:16:28 2017 From: pe3ak at yahoo.com (Vova) Date: Tue, 7 Feb 2017 20:16:28 +0000 (UTC) Subject: [ITK-users] ITK TubeTK Module References: <872656895.3037131.1486498588647.ref@mail.yahoo.com> Message-ID: <872656895.3037131.1486498588647@mail.yahoo.com> Hi New version of ITK 4.11 has TubeTK module included there. When I am trying to Generate the project in CMake (windows 10) following successful configuration step I am getting the ?error: CMake Error in Modules/Remote/TubeTKITK/Base/Registration/CMakeLists.txt: Target "TubeTKRegistration" INTERFACE_INCLUDE_DIRECTORIES property contains path: "D:/ITK/InsightToolkit-4.11.0/Modules/Remote/TubeTKITK/Base/Registration" which is prefixed in the source directory. CMake Error in Modules/Remote/TubeTKITK/Base/Segmentation/CMakeLists.txt: Target "TubeTKSegmentation" INTERFACE_INCLUDE_DIRECTORIES property contains path: "D:/ITK/InsightToolkit-4.11.0/Modules/Remote/TubeTKITK/Base/Segmentation" which is prefixed in the source directory. Is there any way around this problem for CMake to generate the project ? Regards, Vlad. -------------- next part -------------- An HTML attachment was scrubbed... URL: From matt.mccormick at kitware.com Tue Feb 7 15:21:41 2017 From: matt.mccormick at kitware.com (Matt McCormick) Date: Tue, 7 Feb 2017 15:21:41 -0500 Subject: [ITK-users] ITK TubeTK Module In-Reply-To: <872656895.3037131.1486498588647@mail.yahoo.com> References: <872656895.3037131.1486498588647.ref@mail.yahoo.com> <872656895.3037131.1486498588647@mail.yahoo.com> Message-ID: Hi Vlad, This module was merged pre-maturely and is still a work in progress. Thanks, Matt On Tue, Feb 7, 2017 at 3:16 PM, Vova via Insight-users wrote: > Hi > > New version of ITK 4.11 has TubeTK module included there. > > When I am trying to Generate the project in CMake (windows 10) following > successful configuration step I am getting the error: > > CMake Error in Modules/Remote/TubeTKITK/Base/Registration/CMakeLists.txt: > Target "TubeTKRegistration" INTERFACE_INCLUDE_DIRECTORIES property contains > path: > > "D:/ITK/InsightToolkit-4.11.0/Modules/Remote/TubeTKITK/Base/Registration" > > which is prefixed in the source directory. > > CMake Error in Modules/Remote/TubeTKITK/Base/Segmentation/CMakeLists.txt: > Target "TubeTKSegmentation" INTERFACE_INCLUDE_DIRECTORIES property contains > path: > > "D:/ITK/InsightToolkit-4.11.0/Modules/Remote/TubeTKITK/Base/Segmentation" > > which is prefixed in the source directory. > > Is there any way around this problem for CMake to generate the project ? > > Regards, > > Vlad. > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > From deman.pierre at gmail.com Wed Feb 8 12:10:06 2017 From: deman.pierre at gmail.com (pdeman) Date: Wed, 8 Feb 2017 10:10:06 -0700 (MST) Subject: [ITK-users] problem installation from git Message-ID: <1486573806190-7589605.post@n2.nabble.com> Hi, I have made a git clone, did the "configuration" using ccmake. I am working on ubuntu 14.04 and now, when I try to do the make, I have an error message saying "Protocol https not supported or disabled in libcurl" but they are enabled... I have the last version of curl and done the configuration --with-ssl. I have SSL support: enabled (OpenSSL) and Protocols: ... HTTP HTTPS etc ... I don't get the error ... regards -- View this message in context: http://itk-insight-users.2283740.n2.nabble.com/problem-installation-from-git-tp7589605.html Sent from the ITK Insight Users mailing list archive at Nabble.com. From francois.budin at kitware.com Wed Feb 8 14:31:30 2017 From: francois.budin at kitware.com (Francois Budin) Date: Wed, 8 Feb 2017 14:31:30 -0500 Subject: [ITK-users] problem installation from git In-Reply-To: <1486573806190-7589605.post@n2.nabble.com> References: <1486573806190-7589605.post@n2.nabble.com> Message-ID: Hello Pierre, Did you compile CMake yourself or are you using the one packaged with Ubuntu 14.04? Could you run the following commands on your computer and let us know what results you got? 1) cmake --version 2) which cmake 3) strings `which cmake` |grep OPENSSL Thanks, Francois On Wed, Feb 8, 2017 at 12:10 PM, pdeman wrote: > Hi, > > I have made a git clone, did the "configuration" using ccmake. > I am working on ubuntu 14.04 > and now, when I try to do the make, I have an error message saying > "Protocol > https not supported or disabled in libcurl" but they are enabled... > I have the last version of curl and done the configuration --with-ssl. > I have SSL support: enabled (OpenSSL) > and Protocols: ... HTTP HTTPS etc ... > > I don't get the error ... > > regards > > > > -- > View this message in context: http://itk-insight-users. > 2283740.n2.nabble.com/problem-installation-from-git-tp7589605.html > Sent from the ITK Insight Users mailing list archive at Nabble.com. > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From deman.pierre at gmail.com Thu Feb 9 06:13:15 2017 From: deman.pierre at gmail.com (pdeman) Date: Thu, 9 Feb 2017 04:13:15 -0700 (MST) Subject: [ITK-users] problem installation from git In-Reply-To: References: <1486573806190-7589605.post@n2.nabble.com> Message-ID: Hi, I add to download a version of cmake. so I have the version 3.5.2 now. which cmake give me /usr/local/bin/cmake I haven't get what I have to type for 3. if I copy directly without changing anything i have "no return", no error but nothing is replied. Thanks On Wed, Feb 8, 2017 at 8:32 PM, Francois Budin-3 [via ITK Insight Users] < ml-node+s2283740n7589606h40 at n2.nabble.com> wrote: > Hello Pierre, > > Did you compile CMake yourself or are you using the one packaged with > Ubuntu 14.04? > Could you run the following commands on your computer and let us know what > results you got? > 1) cmake --version > 2) which cmake > 3) strings `which cmake` |grep OPENSSL > > Thanks, > Francois > > > On Wed, Feb 8, 2017 at 12:10 PM, pdeman <[hidden email] > > wrote: > >> Hi, >> >> I have made a git clone, did the "configuration" using ccmake. >> I am working on ubuntu 14.04 >> and now, when I try to do the make, I have an error message saying >> "Protocol >> https not supported or disabled in libcurl" but they are enabled... >> I have the last version of curl and done the configuration --with-ssl. >> I have SSL support: enabled (OpenSSL) >> and Protocols: ... HTTP HTTPS etc ... >> >> I don't get the error ... >> >> regards >> >> >> >> -- >> View this message in context: http://itk-insight-users.22837 >> 40.n2.nabble.com/problem-installation-from-git-tp7589605.html >> Sent from the ITK Insight Users mailing list archive at Nabble.com. >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > http://itk-insight-users.2283740.n2.nabble.com/problem- > installation-from-git-tp7589605p7589606.html > To unsubscribe from problem installation from git, click here > > . > NAML > > -- DEMAN Pierre Mobile : +33 7 82 57 80 94 -- View this message in context: http://itk-insight-users.2283740.n2.nabble.com/problem-installation-from-git-tp7589605p7589609.html Sent from the ITK Insight Users mailing list archive at Nabble.com. From dzenanz at gmail.com Thu Feb 9 10:02:32 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Thu, 9 Feb 2017 10:02:32 -0500 Subject: [ITK-users] problem installation from git In-Reply-To: References: <1486573806190-7589605.post@n2.nabble.com> Message-ID: Hi Pierre, your original problem was that CMake was not built with SSL support. If you built it yourself, enable SSL support by e.g. linking to system curl. Probably the easiest solution is to download a pre-compiled binary for your OS and use that. Regards, D?enan On Thu, Feb 9, 2017 at 6:13 AM, pdeman wrote: > Hi, > > I add to download a version of cmake. > so I have the version 3.5.2 now. > which cmake give me /usr/local/bin/cmake > > I haven't get what I have to type for 3. > if I copy directly without changing anything > i have "no return", no error but nothing is replied. > > Thanks > > On Wed, Feb 8, 2017 at 8:32 PM, Francois Budin-3 [via ITK Insight Users] < > ml-node+s2283740n7589606h40 at n2.nabble.com> wrote: > > > Hello Pierre, > > > > Did you compile CMake yourself or are you using the one packaged with > > Ubuntu 14.04? > > Could you run the following commands on your computer and let us know > what > > results you got? > > 1) cmake --version > > 2) which cmake > > 3) strings `which cmake` |grep OPENSSL > > > > Thanks, > > Francois > > > > > > On Wed, Feb 8, 2017 at 12:10 PM, pdeman <[hidden email] > > > wrote: > > > >> Hi, > >> > >> I have made a git clone, did the "configuration" using ccmake. > >> I am working on ubuntu 14.04 > >> and now, when I try to do the make, I have an error message saying > >> "Protocol > >> https not supported or disabled in libcurl" but they are enabled... > >> I have the last version of curl and done the configuration --with-ssl. > >> I have SSL support: enabled (OpenSSL) > >> and Protocols: ... HTTP HTTPS etc ... > >> > >> I don't get the error ... > >> > >> regards > >> > >> > >> > >> -- > >> View this message in context: http://itk-insight-users.22837 > >> 40.n2.nabble.com/problem-installation-from-git-tp7589605.html > >> Sent from the ITK Insight Users mailing list archive at Nabble.com. > >> _____________________________________ > >> 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://public.kitware.com/mailman/listinfo/insight-users > >> > > > > > > _____________________________________ > > 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://public.kitware.com/mailman/listinfo/insight-users > > > > > > ------------------------------ > > If you reply to this email, your message will be added to the discussion > > below: > > http://itk-insight-users.2283740.n2.nabble.com/problem- > > installation-from-git-tp7589605p7589606.html > > To unsubscribe from problem installation from git, click here > > template/NamlServlet.jtp?macro=unsubscribe_by_code&node=7589605&code= > ZGVtYW4ucGllcnJlQGdtYWlsLmNvbXw3NTg5NjA1fDIxMDcyMjE0Mzc=> > > . > > NAML > > template/NamlServlet.jtp?macro=macro_viewer&id=instant_ > html%21nabble%3Aemail.naml&base=nabble.naml.namespaces. > BasicNamespace-nabble.view.web.template.NabbleNamespace- > nabble.view.web.template.NodeNamespace&breadcrumbs= > notify_subscribers%21nabble%3Aemail.naml-instant_emails% > 21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml> > > > > > > -- > DEMAN Pierre > Mobile : +33 7 82 57 80 94 > > > > > -- > View this message in context: http://itk-insight-users. > 2283740.n2.nabble.com/problem-installation-from-git-tp7589605p7589609.html > Sent from the ITK Insight Users mailing list archive at Nabble.com. > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From deman.pierre at gmail.com Fri Feb 10 02:48:24 2017 From: deman.pierre at gmail.com (pdeman) Date: Fri, 10 Feb 2017 00:48:24 -0700 (MST) Subject: [ITK-users] problem installation from git In-Reply-To: References: <1486573806190-7589605.post@n2.nabble.com> Message-ID: Hi, I have download the binary for cmake 3.8. but in a terminal if I do cmake --version it's still the 3.5. How do I make the 3.8 the by default one ? Pierre On Thu, Feb 9, 2017 at 4:03 PM, dzenanz [via ITK Insight Users] < ml-node+s2283740n7589610h64 at n2.nabble.com> wrote: > Hi Pierre, > > your original problem was that CMake was not built with SSL support. If > you built it yourself, enable SSL support by e.g. linking to system curl. > Probably the easiest solution is to download > a pre-compiled binary for your OS and use that. > > Regards, > D?enan > > On Thu, Feb 9, 2017 at 6:13 AM, pdeman <[hidden email] > > wrote: > >> Hi, >> >> I add to download a version of cmake. >> so I have the version 3.5.2 now. >> which cmake give me /usr/local/bin/cmake >> >> I haven't get what I have to type for 3. >> if I copy directly without changing anything >> i have "no return", no error but nothing is replied. >> >> Thanks >> >> On Wed, Feb 8, 2017 at 8:32 PM, Francois Budin-3 [via ITK Insight Users] < >> [hidden email] > >> wrote: >> >> > Hello Pierre, >> > >> > Did you compile CMake yourself or are you using the one packaged with >> > Ubuntu 14.04? >> > Could you run the following commands on your computer and let us know >> what >> > results you got? >> > 1) cmake --version >> > 2) which cmake >> > 3) strings `which cmake` |grep OPENSSL >> > >> > Thanks, >> > Francois >> > >> > >> > On Wed, Feb 8, 2017 at 12:10 PM, pdeman <[hidden email] >> > > wrote: >> > >> >> Hi, >> >> >> >> I have made a git clone, did the "configuration" using ccmake. >> >> I am working on ubuntu 14.04 >> >> and now, when I try to do the make, I have an error message saying >> >> "Protocol >> >> https not supported or disabled in libcurl" but they are enabled... >> >> I have the last version of curl and done the configuration --with-ssl. >> >> I have SSL support: enabled (OpenSSL) >> >> and Protocols: ... HTTP HTTPS etc ... >> >> >> >> I don't get the error ... >> >> >> >> regards >> >> >> >> >> >> >> >> -- >> >> View this message in context: http://itk-insight-users.22837 >> >> 40.n2.nabble.com/problem-installation-from-git-tp7589605.html >> >> Sent from the ITK Insight Users mailing list archive at Nabble.com. >> >> _____________________________________ >> >> 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://public.kitware.com/mailman/listinfo/insight-users >> >> >> > >> > >> > _____________________________________ >> > 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://public.kitware.com/mailman/listinfo/insight-users >> > >> > >> > ------------------------------ >> > If you reply to this email, your message will be added to the discussion >> > below: >> > http://itk-insight-users.2283740.n2.nabble.com/problem- >> > installation-from-git-tp7589605p7589606.html >> > To unsubscribe from problem installation from git, click here >> > > NamlServlet.jtp?macro=unsubscribe_by_code&node= >> 7589605&code=ZGVtYW4ucGllcnJlQGdtYWlsLmNvbXw3NTg5NjA1fDIxMDcyMjE0Mzc=> >> > . >> > NAML >> > > NamlServlet.jtp?macro=macro_viewer&id=instant_html% >> 21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNa >> mespace-nabble.view.web.template.NabbleNamespace-nabbl >> e.view.web.template.NodeNamespace&breadcrumbs=notify_ >> subscribers%21nabble%3Aemail.naml-instant_emails%21nabble% >> 3Aemail.naml-send_instant_email%21nabble%3Aemail.naml> >> > >> >> >> >> -- >> DEMAN Pierre >> Mobile : +33 7 82 57 80 94 >> <+33%207%2082%2057%2080%2094> >> >> >> >> >> -- >> View this message in context: http://itk-insight-users.22837 >> 40.n2.nabble.com/problem-installation-from-git-tp7589605p7589609.html >> Sent from the ITK Insight Users mailing list archive at Nabble.com. >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > http://itk-insight-users.2283740.n2.nabble.com/problem- > installation-from-git-tp7589605p7589610.html > To unsubscribe from problem installation from git, click here > > . > NAML > > -- DEMAN Pierre Mobile : +33 7 82 57 80 94 -- View this message in context: http://itk-insight-users.2283740.n2.nabble.com/problem-installation-from-git-tp7589605p7589611.html Sent from the ITK Insight Users mailing list archive at Nabble.com. From cr at neuro.ma.uni-heidelberg.de Fri Feb 10 08:02:16 2017 From: cr at neuro.ma.uni-heidelberg.de (Chr. Rossmanith) Date: Fri, 10 Feb 2017 14:02:16 +0100 Subject: [ITK-users] Fwd: Re: problem installation from git In-Reply-To: References: Message-ID: forgot to send a copy to the list... -------- Forwarded Message -------- Subject: Re: [ITK-users] problem installation from git Date: Fri, 10 Feb 2017 11:01:58 +0100 From: Chr. Rossmanith To: pdeman Hi, sounds like your PATH variable is set to a value, that cmake 3.5 is found first. Where did you install cmake 3.8? Make sure that this path is listed before the cmake 3.5 path in your PATH variable. 1) echo $PATH shows you the list of paths searched for executables 2) locate -b '\cmake'|grep bin shows you where cmake executables are living on your machine Regards, Christina On 10.02.2017 08:48, pdeman wrote: > Hi,I have download the binary for cmake 3.8.but in a terminal if I do cmake --version it's still the 3.5. > How do I make the 3.8 the by default one ? > Pierre > On Thu, Feb 9, 2017 at 4:03 PM, dzenanz [via ITK Insight Users] wrote: >> Hi Pierre,>> your original problem was that CMake was not built with SSL support. If> you built it yourself, enable SSL support by e.g. linkingto system curl.> Probably the easiest solution is to download > a pre-compiled binary for your OS and use that.>> Regards,> D?enan>> On Thu, Feb 9, 2017 at 6:13 AM, pdeman <[hidden email]> > wrote:>>> Hi,>>>> I add to download a version of cmake.>> so I have the version 3.5.2 now.>> which cmake give me /usr/local/bin/cmake>>>> I haven't getwhat I have to type for 3.>> if I copy directly without changing anything>> i have "no return", no error but nothing is replied.>>>> Thanks>>>> On Wed, Feb 8, 2017 at 8:32 PM, Francois Budin-3 [via ITK Insight Users] <>> [hidden email] >>> wrote:>>>> > Hello Pierre,>> >>> > Did you compile CMake yourself or are you using the one packaged with>> > Ubuntu 14.04?>> > Could yourun the following commands on your computer and let us know>> what>> > results you got?>> > 1) cmake --version>> > 2) which cmake>> > 3) strings `which cmake` |grep OPENSSL>> >>> > Thanks,>> > Francois>> >>> >>> > On Wed, Feb 8, 2017 at 12:10 PM, pdeman <[hidden email]>> > > wrote:>> >>> >> Hi,>> >>>> >> I have made a git clone, did the "configuration" using ccmake.>> >> I am working on ubuntu 14.04>> >> and now, when I try to do the make, I have an error message saying>> >> "Protocol>> >> https not supported or disabled in libcurl" but they are enabled...>> >> I have the last version of curl and done the configuration --with-ssl.>> >> I have SSL support: enabled (OpenSSL)>> >> and Protocols: ... HTTP HTTPS etc ...>> >>>> >> I don't get the error ...>> >>>> >> regards>> >>>> >>>> >>>> >> -->> >> View this message in context: http://itk-insight-users.22837>> >> 40.n2.nabble.com/problem-installation-from-git-tp7589605.html>> >> Sent from the ITK Insight Users mailing list archive at Nabble.com.>> >> _____________________________________>> >> 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://public.kitware.com/mailman/listinfo/insight-users>> >>>>>>> >>> > _____________________________________>> > 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://public.kitware.com/mailman/listinfo/insight-users>> >>> >>> > ------------------------------>> > If you replyto this email, your message will be added to the discussion>> > below:>>> http://itk-insight-users.2283740.n2.nabble.com/problem->> > installation-from-git-tp7589605p7589606.html>> > To unsubscribe from problem installation from git, click here>> > > NamlServlet.jtp?macro=unsubscribe_by_code&node=>> 7589605&code=ZGVtYW4ucGllcnJlQGdtYWlsLmNvbXw3NTg5NjA1fDIxMDcyMjE0Mzc=>>> > .>> > NAML>> > > NamlServlet.jtp?macro=macro_viewer&id=instant_html%>> 21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNa>> mespace-nabble.view.web.template.NabbleNamespace-nabbl>> e.view.web.template.NodeNamespace&breadcrumbs=notify_>> subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%>> 3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>>> >>>>>>>>> -->> DEMAN Pierre>> Mobile : +33 7 82 57 80 94>> <+33%207%2082%2057%2080%2094>>>>>>>>>>> -->> View this message in context: http://itk-insight-users.22837>> 40.n2.nabble.com/problem-installation-from-git-tp7589605p7589609.html>> Sent from the ITK Insight Users mailing list archive at Nabble.com.>> _____________________________________>> Powered by www.kitware.com>>>> Visit other Kitware open-source projects at>> http://www.kitware.com/opensource/opensource.html>>>> Kitwareoffers 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://public.kitware.com/mailman/listinfo/insight-users>>>>> _____________________________________> 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://public.kitware.com/mailman/listinfo/insight-users>>> ------------------------------> If you reply to this email, your message will be added to the discussion> below:> http://itk-insight-users.2283740.n2.nabble.com/problem-> installation-from-git-tp7589605p7589610.html> To unsubscribe from problem installation from git, click here> > .> NAML> > > > -- DEMAN PierreMobile : +33 7 82 57 80 94 > > > > --View this message in context: http://itk-insight-users.2283740.n2.nabble.com/problem-installation-from-git-tp7589605p7589611.htmlSent from theITK Insight Users mailing list archive at Nabble.com._____________________________________Powered by www.kitware.com > Visit other Kitware open-source projects athttp://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://public.kitware.com/mailman/listinfo/insight-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From bakkari.abdelkhalek at hotmail.fr Fri Feb 10 15:45:37 2017 From: bakkari.abdelkhalek at hotmail.fr (Abdelkhalek Bakkari) Date: Fri, 10 Feb 2017 20:45:37 +0000 Subject: [ITK-users] Watershed for 3D Image Segmentation - One Seed Point - Message-ID: Dear ITK users, I Would like to know if there is an algorithm in ITK that is proposed for a semi-automatic segmentation of three-dimensional images. One seed location should be chosen like in Region Growing. Thank you in advance. Best regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland -------------- next part -------------- An HTML attachment was scrubbed... URL: From richard.beare at gmail.com Fri Feb 10 16:00:12 2017 From: richard.beare at gmail.com (Richard Beare) Date: Sat, 11 Feb 2017 08:00:12 +1100 Subject: [ITK-users] Watershed for 3D Image Segmentation - One Seed Point - In-Reply-To: References: Message-ID: The greedy approaches, like MorphologicalWatershedFromMarkers, require 2 seeds. One is the background seed. Sometimes that can be something very simple like the image boundary. The advantage of greedy approaches is that you don't need to specify stopping conditions. The cost is obviously the extra seed. Another advantage is that most of the methods naturally support lots of independent seeds, if you want them. On Sat, Feb 11, 2017 at 7:45 AM, Abdelkhalek Bakkari < bakkari.abdelkhalek at hotmail.fr> wrote: > Dear ITK users, > > > I Would like to know if there is an algorithm in ITK that is proposed for a semi-automatic segmentation of three-dimensional images. > > One seed location should be chosen like in Region Growing. > > Thank you in advance. > > Best regards, > > > Abdelkhalek Bakkari > Ph.D candidate in Computer Science > Institute of Applied Computer Science > Lodz University of Technology, Poland > > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bakkari.abdelkhalek at hotmail.fr Sat Feb 11 10:58:16 2017 From: bakkari.abdelkhalek at hotmail.fr (Abdelkhalek Bakkari) Date: Sat, 11 Feb 2017 15:58:16 +0000 Subject: [ITK-users] Watershed for 3D Image Segmentation - One Seed Point - In-Reply-To: References: , Message-ID: Dear Dr Richard Beare, I am trying your code source which is published in the insight journal about the " The watershed transform in ITK - discussion and new developments". I debugged the perf3D and mperf3D. However, in the mperf3D, it needs two input images. Could you please explain for me the way of adopting it for a .mha file ? Thank you in advance. Best regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland ________________________________ From: Richard Beare Sent: 10 February 2017 22:00 To: Abdelkhalek Bakkari Cc: insight-users Subject: Re: [ITK-users] Watershed for 3D Image Segmentation - One Seed Point - The greedy approaches, like MorphologicalWatershedFromMarkers, require 2 seeds. One is the background seed. Sometimes that can be something very simple like the image boundary. The advantage of greedy approaches is that you don't need to specify stopping conditions. The cost is obviously the extra seed. Another advantage is that most of the methods naturally support lots of independent seeds, if you want them. On Sat, Feb 11, 2017 at 7:45 AM, Abdelkhalek Bakkari > wrote: Dear ITK users, I Would like to know if there is an algorithm in ITK that is proposed for a semi-automatic segmentation of three-dimensional images. One seed location should be chosen like in Region Growing. Thank you in advance. Best regards, Abdelkhalek Bakkari Ph.D candidate in Computer Science Institute of Applied Computer Science Lodz University of Technology, Poland _____________________________________ 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://public.kitware.com/mailman/listinfo/insight-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From richard.beare at gmail.com Sat Feb 11 16:41:54 2017 From: richard.beare at gmail.com (Richard Beare) Date: Sun, 12 Feb 2017 08:41:54 +1100 Subject: [ITK-users] Watershed for 3D Image Segmentation - One Seed Point - In-Reply-To: References: Message-ID: The usual thing I do when testing watersheds in a new application is to manually create marker images using an image segmentation tool, such as itksnap or fslview. The format of the image doesn't matter, as long as ITK can read it. The key thing is to make sure you save a label image - i.e one with each marker having a different voxel value. This gives you an idea of how sensitive the problem is to marker placement and what sort of control image you might need. On Sun, Feb 12, 2017 at 2:58 AM, Abdelkhalek Bakkari < bakkari.abdelkhalek at hotmail.fr> wrote: > Dear Dr Richard Beare, > > > I am trying your code source which is published in the insight journal > about the " The watershed transform in ITK - discussion and new > developments". > > > I debugged the perf3D and mperf3D. However, in the mperf3D, it needs two > input images. Could you please explain for me the way of adopting it for a > .mha file ? > > > Thank you in advance. > > > Best regards, > > > Abdelkhalek Bakkari > Ph.D candidate in Computer Science > Institute of Applied Computer Science > Lodz University of Technology, Poland > > > > > ------------------------------ > *From:* Richard Beare > *Sent:* 10 February 2017 22:00 > *To:* Abdelkhalek Bakkari > *Cc:* insight-users > *Subject:* Re: [ITK-users] Watershed for 3D Image Segmentation - One Seed > Point - > > The greedy approaches, like MorphologicalWatershedFromMarkers, require 2 > seeds. One is the background seed. Sometimes that can be something very > simple like the image boundary. The advantage of greedy approaches is that > you don't need to specify stopping conditions. The cost is obviously the > extra seed. Another advantage is that most of the methods naturally > support lots of independent seeds, if you want them. > > On Sat, Feb 11, 2017 at 7:45 AM, Abdelkhalek Bakkari < > bakkari.abdelkhalek at hotmail.fr> wrote: > >> Dear ITK users, >> >> >> I Would like to know if there is an algorithm in ITK that is proposed for a semi-automatic segmentation of three-dimensional images. >> >> One seed location should be chosen like in Region Growing. >> >> Thank you in advance. >> >> Best regards, >> >> >> Abdelkhalek Bakkari >> Ph.D candidate in Computer Science >> Institute of Applied Computer Science >> Lodz University of Technology, Poland >> >> >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From swetha.bsharma at gmail.com Mon Feb 13 07:00:06 2017 From: swetha.bsharma at gmail.com (Swetha Sharma) Date: Mon, 13 Feb 2017 17:30:06 +0530 Subject: [ITK-users] set center for affinetransform Message-ID: Hi All, I want the set the center of rotation for the affinetransform .I used the function setCenter function ,the signature is defined as setCenter(itk::MatrixOffsetTransformBase::InputType¢er).I tried to set the center in the following way, itk::MatrixOffsetTransformBase centerType; "itk::MatrixOffsetTransformBase::MatrixOffsetTransformBase() [with TParametersValueType=double, NInputDimensions=3U, NOutputDimensions=3U]" (declared at line 482 of "D:\itk\InsightToolkit-4.9.1\src\Modules\Core\Transform\include\itkMatrixOffsetTransformBase.h") is inaccessible Is it possible to define the center of rotation point for the transform? How do I do it? -swetha -------------- next part -------------- An HTML attachment was scrubbed... URL: From dzenanz at gmail.com Mon Feb 13 09:43:20 2017 From: dzenanz at gmail.com (=?UTF-8?B?RMW+ZW5hbiBadWtpxIc=?=) Date: Mon, 13 Feb 2017 09:43:20 -0500 Subject: [ITK-users] set center for affinetransform In-Reply-To: References: Message-ID: Hi Swetha, of course it is possible. CenterType is just a typedef for point. So you have two ways. First uses transform type to get center type: typedef itk::AffineTransform TransformType; TransformType::CenterType center; transform->SetCenter(center); Second typedefs point directly: typedef itk::Point CenterType; CenterType center; transform->SetCenter(center); Regards, D?enan On Mon, Feb 13, 2017 at 7:00 AM, Swetha Sharma wrote: > Hi All, > > I want the set the center of rotation for the affinetransform .I used > the function setCenter function ,the signature is defined as setCenter(itk:: > MatrixOffsetTransformBase::InputType¢er).I tried to set > the center in the following way, > > itk::MatrixOffsetTransformBase centerType; > > "itk::MatrixOffsetTransformBase NOutputDimensions>::MatrixOffsetTransformBase() [with > TParametersValueType=double, NInputDimensions=3U, NOutputDimensions=3U]" > (declared at line 482 of "D:\itk\InsightToolkit-4.9.1\ > src\Modules\Core\Transform\include\itkMatrixOffsetTransformBase.h") is > inaccessible > > > Is it possible to define the center of rotation point for the transform? > How do I do it? > -swetha > > > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From swetha.bsharma at gmail.com Mon Feb 13 12:17:18 2017 From: swetha.bsharma at gmail.com (Swetha Sharma) Date: Mon, 13 Feb 2017 17:17:18 +0000 Subject: [ITK-users] set center for affinetransform In-Reply-To: References: Message-ID: Thanks. On Mon, 13 Feb 2017, 20:13 D?enan Zuki?, wrote: > Hi Swetha, > > of course it is possible. CenterType is just a typedef for point. So you > have two ways. First uses transform type to get center type: > typedef itk::AffineTransform TransformType; > TransformType::CenterType center; > transform->SetCenter(center); > > Second typedefs point directly: > typedef itk::Point CenterType; > CenterType center; > transform->SetCenter(center); > > Regards, > D?enan > > On Mon, Feb 13, 2017 at 7:00 AM, Swetha Sharma > wrote: > > Hi All, > > I want the set the center of rotation for the affinetransform .I used > the function setCenter function ,the signature is defined as > setCenter(itk::MatrixOffsetTransformBase::InputType¢er).I > tried to set the center in the following way, > > itk::MatrixOffsetTransformBase centerType; > > "itk::MatrixOffsetTransformBase NOutputDimensions>::MatrixOffsetTransformBase() [with > TParametersValueType=double, NInputDimensions=3U, NOutputDimensions=3U]" > (declared at line 482 of > "D:\itk\InsightToolkit-4.9.1\src\Modules\Core\Transform\include\itkMatrixOffsetTransformBase.h") > is inaccessible > > > Is it possible to define the center of rotation point for the transform? > How do I do it? > -swetha > > > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ibr_ex at yahoo.com Wed Feb 15 07:35:10 2017 From: ibr_ex at yahoo.com (Ibraheem) Date: Wed, 15 Feb 2017 05:35:10 -0700 (MST) Subject: [ITK-users] DICOM resample for large files Message-ID: <1487162110931-37916.post@n7.nabble.com> Dear all, I am trying to resample large dicom volume by using the code from this example: https://itk.org/Wiki/ITK/Examples/DICOM/ResampleDICOM but I get out of memory error. I did the following: 1- divide the files into different folders e.g each folder contains only 100 files e.g. folder1/file0 to file99 folder2/file100 to file199 2- resample each folder separately. 3- collect the files again to one folder. I had a problem that the code name the files in each folder the same e.g. folder1/file0 to file99 folder2/file0 to file99 ... I solved this problem by getting the index from the files names in each folder. When I try to read the resulted volume I get multiple volumes with same contents. Each volume display only small part of the original volume and the rest is black. It looks like the code overwriting each folder with images of the first folder even the names are changed. The code can be viewed/downloaded from this link: https://drive.google.com/open?id=0B6CYc5oVUOLSMDd6cVdfSGlmRkU Your suggestion is appreciated. Regards, Ibraheem -- View this message in context: http://itk-users.7.n7.nabble.com/DICOM-resample-for-large-files-tp37916.html Sent from the ITK - Users mailing list archive at Nabble.com. From aharr8 at uwo.ca Wed Feb 15 09:39:03 2017 From: aharr8 at uwo.ca (Andrew Harris) Date: Wed, 15 Feb 2017 09:39:03 -0500 Subject: [ITK-users] [ITK] Combining two images after registration Message-ID: Hello, Hopefully someone can point me in the right direction. I have a successful image registration between two images of the same size I have confirmed by outputting two .mha files and blending them in Slicer. What I would like to be able to do is to combine them within C++ and output a single .mha file. As a further complication, part of the moving image gets left off because the image rotates outside the bounds of the original image size, and it would be preferable if I could figure out how to pad the moving image automatically in the dimensions necessary to prevent this from happening. Any thoughts are welcome. -- AH ----------------------------------------------------------------------------------------------- *This email and any attachments thereto may contain private, confidential, and privileged materials for the sole use of the intended recipient. Any reviewing, copying, or distribution of this email (or any attachments thereto) by other than the intended recipient is strictly prohibited. If you are not the intended recipient, please contact the sender immediately and permanently destroy this email and any attachments thereto.* -------------- next part -------------- An HTML attachment was scrubbed... URL: From ibr_ex at yahoo.com Wed Feb 15 09:42:36 2017 From: ibr_ex at yahoo.com (ibraheem aldhamari) Date: Wed, 15 Feb 2017 14:42:36 +0000 (UTC) Subject: [ITK-users] [ITK] Combining two images after registration In-Reply-To: References: Message-ID: <1794402278.6753322.1487169757019@mail.yahoo.com> Hey,?In Slicer you can use Add Scalar Volume plugin. ?In itk?use this :? ??https://itk.org/Doxygen/html/classitk_1_1AddImageFilter.html? ??https://itk.org/Wiki/ITK/Examples/ImageProcessing/AddImageFilter Best regards and have a nice day!Ibraheem? From: Andrew Harris To: Insight-users Sent: Wednesday, February 15, 2017 3:39 PM Subject: [ITK-users] [ITK] Combining two images after registration Hello,Hopefully someone can point me in the right direction.? I have a successful image registration between two images of the same size I have confirmed by outputting two .mha files and blending them in Slicer.? What I would like to be able to do is to combine them within C++ and output a single .mha file. As a further complication, part of the moving image gets left off because the image rotates outside the bounds of the original image size, and it would be preferable if I could figure out how to pad the moving image automatically in the dimensions necessary to prevent this from happening. Any thoughts are welcome. --AH -----------------------------------------------------------------------------------------------This email and any attachments thereto may contain private, confidential,?and?privileged materials for the sole use of the intended recipient. Any?reviewing, copying, or distribution of this email (or any attachments thereto)?by other than the intended recipient is strictly prohibited. If you are not?the intended recipient, please contact the sender immediately and?permanently destroy this email and any attachments thereto. _____________________________________ 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://public.kitware.com/mailman/listinfo/insight-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From aharr8 at uwo.ca Wed Feb 15 10:01:22 2017 From: aharr8 at uwo.ca (Andrew Harris) Date: Wed, 15 Feb 2017 10:01:22 -0500 Subject: [ITK-users] [ITK] Combining two images after registration In-Reply-To: <1794402278.6753322.1487169757019@mail.yahoo.com> References: <1794402278.6753322.1487169757019@mail.yahoo.com> Message-ID: Thanks for getting back to me, I looked at that filter and it has a warning that said ?No numeric overflow checking is performed in this filter?, so I assumed that meant that if I put an image through it there would be a simple addition pixelwise across the image. That would make the overlap region brighter than the non-overlap region which I was trying to avoid. -- AH ----------------------------------------------------------------------------------------------- *This email and any attachments thereto may contain private, confidential, and privileged materials for the sole use of the intended recipient. Any reviewing, copying, or distribution of this email (or any attachments thereto) by other than the intended recipient is strictly prohibited. If you are not the intended recipient, please contact the sender immediately and permanently destroy this email and any attachments thereto.* On Wed, Feb 15, 2017 at 9:42 AM, ibraheem aldhamari wrote: > Hey, > In Slicer you can use Add Scalar Volume plugin. > In itk use this : > https://itk.org/Doxygen/html/classitk_1_1AddImageFilter.html > https://itk.org/Wiki/ITK/Examples/ImageProcessing/AddImageFilter > > Best regards and have a nice day! > Ibraheem > > > ------------------------------ > *From:* Andrew Harris > *To:* Insight-users > *Sent:* Wednesday, February 15, 2017 3:39 PM > *Subject:* [ITK-users] [ITK] Combining two images after registration > > Hello, > Hopefully someone can point me in the right direction. I have a > successful image registration between two images of the same size I have > confirmed by outputting two .mha files and blending them in Slicer. What I > would like to be able to do is to combine them within C++ and output a > single .mha file. As a further complication, part of the moving image gets > left off because the image rotates outside the bounds of the original image > size, and it would be preferable if I could figure out how to pad the > moving image automatically in the dimensions necessary to prevent this from > happening. > > Any thoughts are welcome. > -- > AH > > ------------------------------------------------------------ > ----------------------------------- > *This email and any attachments thereto may contain private, > confidential, and privileged materials for the sole use of the intended > recipient. Any reviewing, copying, or distribution of this email (or any > attachments thereto) by other than the intended recipient is strictly > prohibited. If you are not the intended recipient, please contact the > sender immediately and permanently destroy this email and any attachments > thereto.* > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ibr_ex at yahoo.com Wed Feb 15 10:07:36 2017 From: ibr_ex at yahoo.com (ibraheem aldhamari) Date: Wed, 15 Feb 2017 15:07:36 +0000 (UTC) Subject: [ITK-users] [ITK] Combining two images after registration In-Reply-To: References: <1794402278.6753322.1487169757019@mail.yahoo.com> Message-ID: <828723854.6878428.1487171256467@mail.yahoo.com> save the images in the same datatype then multiply?each image by 0.5 before adding?https://itk.org/ITKExamples/src/Filtering/ImageIntensity/MultiplyImageByScalar/Documentation.html? Best regards and have a nice day!Ibraheem?? From: Andrew Harris To: ibraheem aldhamari Cc: Insight-users Sent: Wednesday, February 15, 2017 4:01 PM Subject: Re: [ITK-users] [ITK] Combining two images after registration Thanks for getting back to me,I looked at that filter and it has a warning that said ?No numeric overflow checking is performed in this filter?, so I assumed that meant that if I put an image through it there would be a simple addition pixelwise across the image.? That would make the overlap region brighter than the non-overlap region which I was trying to avoid.? --AH -----------------------------------------------------------------------------------------------This email and any attachments thereto may contain private, confidential,?and?privileged materials for the sole use of the intended recipient. Any?reviewing, copying, or distribution of this email (or any attachments thereto)?by other than the intended recipient is strictly prohibited. If you are not?the intended recipient, please contact the sender immediately and?permanently destroy this email and any attachments thereto. On Wed, Feb 15, 2017 at 9:42 AM, ibraheem aldhamari wrote: Hey,?In Slicer you can use Add Scalar Volume plugin. ?In itk?use this :? ??https://itk.org/Doxygen/ html/classitk_1_ 1AddImageFilter.html? ??https://itk.org/Wiki/ITK/ Examples/ImageProcessing/ AddImageFilter Best regards and have a nice day!Ibraheem? From: Andrew Harris To: Insight-users Sent: Wednesday, February 15, 2017 3:39 PM Subject: [ITK-users] [ITK] Combining two images after registration Hello,Hopefully someone can point me in the right direction.? I have a successful image registration between two images of the same size I have confirmed by outputting two .mha files and blending them in Slicer.? What I would like to be able to do is to combine them within C++ and output a single .mha file. As a further complication, part of the moving image gets left off because the image rotates outside the bounds of the original image size, and it would be preferable if I could figure out how to pad the moving image automatically in the dimensions necessary to prevent this from happening. Any thoughts are welcome. --AH ------------------------------ ------------------------------ ------------------------------ -----This email and any attachments thereto may contain private, confidential,?and?privileged materials for the sole use of the intended recipient. Any?reviewing, copying, or distribution of this email (or any attachments thereto)?by other than the intended recipient is strictly prohibited. If you are not?the intended recipient, please contact the sender immediately and?permanently destroy this email and any attachments thereto. ______________________________ _______ 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://public.kitware.com/ mailman/listinfo/insight-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From aharr8 at uwo.ca Wed Feb 15 12:40:26 2017 From: aharr8 at uwo.ca (Andrew Harris) Date: Wed, 15 Feb 2017 12:40:26 -0500 Subject: [ITK-users] [ITK] Combining two images after registration In-Reply-To: <828723854.6878428.1487171256467@mail.yahoo.com> References: <1794402278.6753322.1487169757019@mail.yahoo.com> <828723854.6878428.1487171256467@mail.yahoo.com> Message-ID: That will work for the region inside the overlap region, but the region outside the overlap region would then have their value reduced by half. Is there a filter pre-written that checks for information in the overlap region before doing the scaling? I have something partially written that does that but it doesn't fix the portion of the image that is cut off because it rotates outside the original image bounds. Thanks for your help. -- AH ----------------------------------------------------------------------------------------------- *This email and any attachments thereto may contain private, confidential, and privileged materials for the sole use of the intended recipient. Any reviewing, copying, or distribution of this email (or any attachments thereto) by other than the intended recipient is strictly prohibited. If you are not the intended recipient, please contact the sender immediately and permanently destroy this email and any attachments thereto.* On Wed, Feb 15, 2017 at 10:07 AM, ibraheem aldhamari wrote: > save the images in the same datatype then multiply each image by 0.5 > before adding > https://itk.org/ITKExamples/src/Filtering/ImageIntensity/ > MultiplyImageByScalar/Documentation.html > > > Best regards and have a nice day! > Ibraheem > > > ------------------------------ > *From:* Andrew Harris > *To:* ibraheem aldhamari > *Cc:* Insight-users > *Sent:* Wednesday, February 15, 2017 4:01 PM > *Subject:* Re: [ITK-users] [ITK] Combining two images after registration > > Thanks for getting back to me, > I looked at that filter and it has a warning that said ?No numeric > overflow checking is performed in this filter?, so I assumed that meant > that if I put an image through it there would be a simple addition > pixelwise across the image. That would make the overlap region brighter > than the non-overlap region which I was trying to avoid. > > -- > AH > > ------------------------------------------------------------ > ----------------------------------- > *This email and any attachments thereto may contain private, > confidential, and privileged materials for the sole use of the intended > recipient. Any reviewing, copying, or distribution of this email (or any > attachments thereto) by other than the intended recipient is strictly > prohibited. If you are not the intended recipient, please contact the > sender immediately and permanently destroy this email and any attachments > thereto.* > > On Wed, Feb 15, 2017 at 9:42 AM, ibraheem aldhamari > wrote: > > Hey, > In Slicer you can use Add Scalar Volume plugin. > In itk use this : > https://itk.org/Doxygen/ html/classitk_1_ 1AddImageFilter.html > > https://itk.org/Wiki/ITK/ Examples/ImageProcessing/ AddImageFilter > > > Best regards and have a nice day! > Ibraheem > > > ------------------------------ > *From:* Andrew Harris > *To:* Insight-users > *Sent:* Wednesday, February 15, 2017 3:39 PM > *Subject:* [ITK-users] [ITK] Combining two images after registration > > Hello, > Hopefully someone can point me in the right direction. I have a > successful image registration between two images of the same size I have > confirmed by outputting two .mha files and blending them in Slicer. What I > would like to be able to do is to combine them within C++ and output a > single .mha file. As a further complication, part of the moving image gets > left off because the image rotates outside the bounds of the original image > size, and it would be preferable if I could figure out how to pad the > moving image automatically in the dimensions necessary to prevent this from > happening. > > Any thoughts are welcome. > -- > AH > > ------------------------------ ------------------------------ > ------------------------------ ----- > *This email and any attachments thereto may contain private, > confidential, and privileged materials for the sole use of the intended > recipient. Any reviewing, copying, or distribution of this email (or any > attachments thereto) by other than the intended recipient is strictly > prohibited. If you are not the intended recipient, please contact the > sender immediately and permanently destroy this email and any attachments > thereto.* > > ______________________________ _______ > 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://public.kitware.com/ mailman/listinfo/insight-users > > > > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From blowekamp at mail.nih.gov Thu Feb 16 09:58:06 2017 From: blowekamp at mail.nih.gov (Lowekamp, Bradley (NIH/NLM/LHC) [C]) Date: Thu, 16 Feb 2017 14:58:06 +0000 Subject: [ITK-users] [ANN] SimpleITK 1.0 Release Candidate 1 Message-ID: On behalf of the SimpleITK developers and the Insight Software Consortium community, we please to announce the release of the SimpleITK 1.0 Release Candidate 1! For the first release candidate we are only providing source code distributions. The source-balls can be found on GitHub(https://github.com/SimpleITK/SimpleITK/releases/tag/v1.0rc1) and SourceForge (https://sourceforge.net/projects/simpleitk/files/SimpleITK/1.0rc1/Source/). We encourage users to try to build SimpleITK v1.0rc1 from the source (https://itk.org/Wiki/SimpleITK/GettingStarted#Build_It_Yourself). There are a number of new and updated language specific "front-ends" to use: - Python - https://github.com/SimpleITK/SimpleITKPythonPackage - R - https://github.com/SimpleITK/SimpleITKRInstaller - Lua - https://github.com/SimpleITK/SimpleITKLuaRock - Anaconda - https://github.com/SimpleITK/SimpleITKCondaRecipe Release Notes: * Key Improvements: - Improved Python data bridge - New Python method `GetArrayViewFromImage` provides copy free read-only access - Updated Python data structures to use `memory view` objects - Building SimpleITK wrappers: - R devtools based installer (https://github.com/SimpleITK/SimpleITKRInstaller). - Python: scripts for building wheels (https://github.com/SimpleITK/SimpleITKPythonPackage) and a Conda recipe (https://github.com/SimpleITK/SimpleITKCondaRecipe). - Support use of virtual image domain in the `ImageRegistrationMethod`. - OnePlusOneOptimizer added to registration framework. - Improved support for R: propogating C++ exceptions into R, additional R tests. - Additional tests for Java. - Python and R notebooks repository illustrating the basics and more advanced functionality of SimpleITK (https://github.com/InsightSoftwareConsortium/SimpleITK-Notebooks). - Added continous integration via CircleCI. - Updated version and improved integration of Google Test. - Updated ITK version to 4.11 - Updated minimal required CMake version to 3.0, and numerous CMake changes to support various build configurations. - Updated to usage of SWIG 3.0.11 ( using the latest SIWG is strongly recommended for R ) - Reorganized examples directory into example based sub-directories with multiple languages - Improvements to documentation transmogrification scripts - Many bug fixes and improvement to the build system! * API changes: - R methods which previously unnecessarily returned self return void. - New method `Image::GetNumberOfPixels` - New method `LabelMapContourOverlayImageFilter::SetColormap` - New method `LabelMapToRGBImageFilter::SetColormap` - New method `ImageRegistrationMethod::SetVirtualDomain` - New method `ImageRegistrationMethod::SetVirtualDomainFromImage` - New seed parameter to `ImageRegistrationMethod::AddMetricSamplingSeed` method - `CastImageFilter::SetOutputPixelType` method no longer accepts the pixel ID by value, uses only enumerated type. Please try out SimpleITK 1.0rc1, and report any issues! Enjoy! Bradley Lowekamp From tamanupadhaya at gmail.com Thu Feb 16 11:42:00 2017 From: tamanupadhaya at gmail.com (Tmn) Date: Thu, 16 Feb 2017 09:42:00 -0700 (MST) Subject: [ITK-users] Grey Level Run Length Matrix Message-ID: <1487263320349-7589629.post@n2.nabble.com> Hi all, I am using itk library to extract Run Length Matrix texture feature using itk::Statistics::ScalarImageToRunLengthMatrixFilter<>; however, the total frequency of the matrix is more than the total number of pixel. For all the 13 different matrices the total frequency is sometime less than and some time higher than total number of pixel. These are the parameter I have provided, do I need to provide more parameter than this ? RunLenFilter->SetOffset(offset); RunLenFilter->SetDistanceValueMinMax( 0, pointMin.EuclideanDistanceTo( pointMax ) ); RunLenFilter->SetPixelValueMinMax(minValue,maxValue); RunLenFilter->SetNumberOfBinsPerAxis(Bins); Can someone please provide me with some inside of Run Length Matrix function/method? Thank you for your time! -- View this message in context: http://itk-insight-users.2283740.n2.nabble.com/Grey-Level-Run-Length-Matrix-tp7589629.html Sent from the ITK Insight Users mailing list archive at Nabble.com. From francois.budin at kitware.com Thu Feb 16 16:45:34 2017 From: francois.budin at kitware.com (Francois Budin) Date: Thu, 16 Feb 2017 16:45:34 -0500 Subject: [ITK-users] [ITK] Combining two images after registration In-Reply-To: References: <1794402278.6753322.1487169757019@mail.yahoo.com> <828723854.6878428.1487171256467@mail.yahoo.com> Message-ID: Hello Andrew, There is currently no complete implementation of what you are doing in ITK. However, there are a few pieces that are available and that you can use. 1) To combine multiple images that partially overlap, you can refer to this insight Journal article [1]. 2) To compute the size of the output image that you need, you can look at [2] (computing transformed image bounding box). 3) If you create a more complete implementation that solves this problem, feel free to contribute to ITK. The easiest way to contribute to ITK is to write an Insight Journal article and implement an external ITK module. You can refer to the ITK software guide for more information about the process [3]. Hope this helps, Francois [1] http://www.insight-journal.org/browse/publication/914 [2] https://github.com/fbudin69500/ITKTransformTools [3] https://itk.org/ITK/help/documentation.html On Wed, Feb 15, 2017 at 12:40 PM, Andrew Harris wrote: > That will work for the region inside the overlap region, but the region > outside the overlap region would then have their value reduced by half. Is > there a filter pre-written that checks for information in the overlap > region before doing the scaling? I have something partially written that > does that but it doesn't fix the portion of the image that is cut off > because it rotates outside the original image bounds. > > Thanks for your help. > > -- > > AH > > > ------------------------------------------------------------ > ----------------------------------- > > *This email and any attachments thereto may contain private, > confidential, and privileged materials for the sole use of the intended > recipient. Any reviewing, copying, or distribution of this email (or any > attachments thereto) by other than the intended recipient is strictly > prohibited. If you are not the intended recipient, please contact the > sender immediately and permanently destroy this email and any attachments > thereto.* > > On Wed, Feb 15, 2017 at 10:07 AM, ibraheem aldhamari > wrote: > >> save the images in the same datatype then multiply each image by 0.5 >> before adding >> https://itk.org/ITKExamples/src/Filtering/ImageIntensity/Mul >> tiplyImageByScalar/Documentation.html >> >> >> Best regards and have a nice day! >> Ibraheem >> >> >> ------------------------------ >> *From:* Andrew Harris >> *To:* ibraheem aldhamari >> *Cc:* Insight-users >> *Sent:* Wednesday, February 15, 2017 4:01 PM >> *Subject:* Re: [ITK-users] [ITK] Combining two images after registration >> >> Thanks for getting back to me, >> I looked at that filter and it has a warning that said ?No numeric >> overflow checking is performed in this filter?, so I assumed that meant >> that if I put an image through it there would be a simple addition >> pixelwise across the image. That would make the overlap region brighter >> than the non-overlap region which I was trying to avoid. >> >> -- >> AH >> >> ------------------------------------------------------------ >> ----------------------------------- >> *This email and any attachments thereto may contain private, >> confidential, and privileged materials for the sole use of the intended >> recipient. Any reviewing, copying, or distribution of this email (or any >> attachments thereto) by other than the intended recipient is strictly >> prohibited. If you are not the intended recipient, please contact the >> sender immediately and permanently destroy this email and any attachments >> thereto.* >> >> On Wed, Feb 15, 2017 at 9:42 AM, ibraheem aldhamari >> wrote: >> >> Hey, >> In Slicer you can use Add Scalar Volume plugin. >> In itk use this : >> https://itk.org/Doxygen/ html/classitk_1_ 1AddImageFilter.html >> >> https://itk.org/Wiki/ITK/ Examples/ImageProcessing/ AddImageFilter >> >> >> Best regards and have a nice day! >> Ibraheem >> >> >> ------------------------------ >> *From:* Andrew Harris >> *To:* Insight-users >> *Sent:* Wednesday, February 15, 2017 3:39 PM >> *Subject:* [ITK-users] [ITK] Combining two images after registration >> >> Hello, >> Hopefully someone can point me in the right direction. I have a >> successful image registration between two images of the same size I have >> confirmed by outputting two .mha files and blending them in Slicer. What I >> would like to be able to do is to combine them within C++ and output a >> single .mha file. As a further complication, part of the moving image gets >> left off because the image rotates outside the bounds of the original image >> size, and it would be preferable if I could figure out how to pad the >> moving image automatically in the dimensions necessary to prevent this from >> happening. >> >> Any thoughts are welcome. >> -- >> AH >> >> ------------------------------ ------------------------------ >> ------------------------------ ----- >> *This email and any attachments thereto may contain private, >> confidential, and privileged materials for the sole use of the intended >> recipient. Any reviewing, copying, or distribution of this email (or any >> attachments thereto) by other than the intended recipient is strictly >> prohibited. If you are not the intended recipient, please contact the >> sender immediately and permanently destroy this email and any attachments >> thereto.* >> >> ______________________________ _______ >> 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://public.kitware.com/ mailman/listinfo/insight-users >> >> >> >> >> >> >> > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nour_sn at hotmail.fr Fri Feb 17 07:30:15 2017 From: nour_sn at hotmail.fr (jaki19) Date: Fri, 17 Feb 2017 05:30:15 -0700 (MST) Subject: [ITK-users] How to add new points inside a 3D structure and connect them with neighboring points Message-ID: <1487334615917-37925.post@n7.nabble.com> Hallo, I have a DICOM images of a vertebra, that I converted to stl file and using vtkreadstlfile I converted it into vtkpolydata. I would like to know if there are some functions that can help me to add some new points (with random coordinates) inside my structure and connect those new points to neighboring points that exist in a specific distance?? Thanks -- View this message in context: http://itk-users.7.n7.nabble.com/How-to-add-new-points-inside-a-3D-structure-and-connect-them-with-neighboring-points-tp37925.html Sent from the ITK - Users mailing list archive at Nabble.com. From mdccnunes at hotmail.com Tue Feb 21 07:29:14 2017 From: mdccnunes at hotmail.com (sharkpt) Date: Tue, 21 Feb 2017 05:29:14 -0700 (MST) Subject: [ITK-users] ITK 4.11 build issue Message-ID: <1487680154437-37926.post@n7.nabble.com> Hello, I have just downloaded the new ITK 4.11 and I am having a couple of issues compiling in Windows 10, 64bit release, Visual Studio (version 12 - update 5). I also have the new AMD APP SDK 3.0 (for openCL libs and includes). The error is as follows: mylibraries\itk\insighttoolkit-4.11.0\modules\core\gpucommon\include\itkGPUImage.h(179): error C3668: 'itk::GPUImage::Graft' : method with override specifier 'override' did not override any base class methods I also went to git hub and downloaded the master. I tried compiling it but got different errors. Any help is appreciated! Best regards Miguel -- View this message in context: http://itk-users.7.n7.nabble.com/ITK-4-11-build-issue-tp37926.html Sent from the ITK - Users mailing list archive at Nabble.com. From francois.budin at kitware.com Tue Feb 21 12:11:02 2017 From: francois.budin at kitware.com (Francois Budin) Date: Tue, 21 Feb 2017 12:11:02 -0500 Subject: [ITK-users] ITK 4.11 build issue In-Reply-To: <1487680154437-37926.post@n7.nabble.com> References: <1487680154437-37926.post@n7.nabble.com> Message-ID: Hello Miguel, Thanks for reporting this issue. I have submitted a patch that should solve the problem. The patch is in review. You can download it and test it [1]. Regards, Francois [1] http://review.source.kitware.com/#/c/22089/ On Tue, Feb 21, 2017 at 7:29 AM, sharkpt wrote: > Hello, > > I have just downloaded the new ITK 4.11 and I am having a couple of issues > compiling in Windows 10, 64bit release, Visual Studio (version 12 - update > 5). > I also have the new AMD APP SDK 3.0 (for openCL libs and includes). > > The error is as follows: > > mylibraries\itk\insighttoolkit-4.11.0\modules\core\gpucommon\include\ > itkGPUImage.h(179): > error C3668: 'itk::GPUImage::Graft' : method with override > specifier 'override' did not override any base class methods > > I also went to git hub and downloaded the master. I tried compiling it but > got different errors. > > Any help is appreciated! > > Best regards > Miguel > > > > -- > View this message in context: http://itk-users.7.n7.nabble. > com/ITK-4-11-build-issue-tp37926.html > Sent from the ITK - Users mailing list archive at Nabble.com. > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mdccnunes at hotmail.com Wed Feb 22 04:04:50 2017 From: mdccnunes at hotmail.com (sharkpt) Date: Wed, 22 Feb 2017 02:04:50 -0700 (MST) Subject: [ITK-users] ITK 4.11 build issue In-Reply-To: References: <1487680154437-37926.post@n7.nabble.com> Message-ID: <1487754290631-37928.post@n7.nabble.com> Francois Budin-3, Thank you for the reply. It worked but 2 other errors appeared related to the override thing: itkGPUImageToImageFilter.h Lines 76 and 77. I manually removed the IT_OVERRIDE and everything compiled. Thanks! -- View this message in context: http://itk-users.7.n7.nabble.com/ITK-4-11-build-issue-tp37926p37928.html Sent from the ITK - Users mailing list archive at Nabble.com. From cyril.mory at creatis.insa-lyon.fr Wed Feb 22 04:38:14 2017 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Wed, 22 Feb 2017 10:38:14 +0100 Subject: [ITK-users] Filter working on both itk::Image and itk::VectorImage In-Reply-To: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> Message-ID: <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> Hi ITK users, I am writing an itk::ImageToImageFilter, and I want the filter to work with T=itk::Image as well as with T=itk::VectorImage. To set/get the vectorLength of an image (which is 1 for an itk::Image, and varies for an itk::VectorImage), I have successfully used the functions Set/GetNumberOfComponentsPerPixel from the itk::ImageBase class, which work for both itk::Image and itk::VectorImage. But I cannot find a way to initialize one of the pixels to a given value, that would work for both cases, i.e. whether that pixel is a scalar or a variableLengthVector. For now, the best I could do is define a function FillPixel in my filter, like this: OutputImagePixelType FillPixel(OutputImageInternalPixelType value) {return value;} and write a template specialization when my filter is instantiated with itk::VectorImage, like this: template <> itk::VariableLengthVector rtk::ConstantImageSource > ::FillPixel(float value) { itk::VariableLengthVector vect; vect.SetSize(this->GetVectorLength()); vect.Fill(value); return (vect); } Did I miss something ? Is there a better way of doing this in ITK ? Looking forward to reading you, Cyril From cyril.mory at creatis.insa-lyon.fr Wed Feb 22 05:52:22 2017 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Wed, 22 Feb 2017 11:52:22 +0100 Subject: [ITK-users] Filter working on both itk::Image and itk::VectorImage In-Reply-To: <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> Message-ID: <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> Answering my own question: I found a way to do what I needed using itk::NumericTraits : OutputImagePixelType pix; itk::NumericTraits::SetLength(pix, this->GetVectorLength()); pix = itk::NumericTraits::OneValue(pix) * value; It works for both cases with the same code. However, if there is a better way (cleaner, safer, more compact, ... whatever the wayin which it is better), I'd be happy to learn about it. Best regards, Cyril On 22/02/2017 10:38, Cyril Mory wrote: > Hi ITK users, > > I am writing an itk::ImageToImageFilter, and I want the filter to > work with T=itk::Image as well as with T=itk::VectorImage. > > To set/get the vectorLength of an image (which is 1 for an itk::Image, > and varies for an itk::VectorImage), I have successfully used the > functions Set/GetNumberOfComponentsPerPixel from the itk::ImageBase > class, which work for both itk::Image and itk::VectorImage. > > But I cannot find a way to initialize one of the pixels to a given > value, that would work for both cases, i.e. whether that pixel is a > scalar or a variableLengthVector. For now, the best I could do is > define a function FillPixel in my filter, like this: > > OutputImagePixelType FillPixel(OutputImageInternalPixelType value) > {return value;} > > and write a template specialization when my filter is instantiated > with itk::VectorImage, like this: > > template <> > itk::VariableLengthVector > rtk::ConstantImageSource > > ::FillPixel(float value) > { > itk::VariableLengthVector vect; > vect.SetSize(this->GetVectorLength()); > vect.Fill(value); > return (vect); > } > > Did I miss something ? Is there a better way of doing this in ITK ? > > Looking forward to reading you, > Cyril > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users From francois.budin at kitware.com Wed Feb 22 10:43:00 2017 From: francois.budin at kitware.com (Francois Budin) Date: Wed, 22 Feb 2017 10:43:00 -0500 Subject: [ITK-users] ITK 4.11 build issue In-Reply-To: <1487754290631-37928.post@n7.nabble.com> References: <1487680154437-37926.post@n7.nabble.com> <1487754290631-37928.post@n7.nabble.com> Message-ID: Thank you for reporting this issue. I just submitted a new patch [1] and this should be integrated in ITK soon. If you create a reviewer profile on Gerrit, I can add you as a reviewer. You can find more information about how to do it here [2] Regards, Francois [1] http://review.source.kitware.com/#/c/22092/1 [2] https://itk.org/Wiki/ITK/Git/Develop On Wed, Feb 22, 2017 at 4:04 AM, sharkpt wrote: > Francois Budin-3, > Thank you for the reply. > > It worked but 2 other errors appeared related to the override thing: > itkGPUImageToImageFilter.h Lines 76 and 77. I manually removed the > IT_OVERRIDE and everything compiled. > > Thanks! > > > > > -- > View this message in context: http://itk-users.7.n7.nabble. > com/ITK-4-11-build-issue-tp37926p37928.html > Sent from the ITK - Users mailing list archive at Nabble.com. > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From davood.karimi at gmail.com Wed Feb 22 10:43:41 2017 From: davood.karimi at gmail.com (engineeringmath) Date: Wed, 22 Feb 2017 08:43:41 -0700 (MST) Subject: [ITK-users] Missing filters in ITK installation Message-ID: <1487778221335-7589640.post@n2.nabble.com> Hello, I have been using SimpleITK for a while. But I recently needed filters that were not available in SimpleITK, so I installed ITK. However, after importing ITK into my python IDE, I see that those filters are not available. Also, searching my computer I cannot find those filters. The filters I am looking for are AverageOutwardFluxImageFilter and MedialCurveImageFilter (please see the links below). Am I making a mistake during the installation? Your help is greatly appreciated. http://www.insight-journal.org/browse/publication/165 http://www.dtic.upf.edu/~afrangi/articles/tij2007.pdf -- View this message in context: http://itk-insight-users.2283740.n2.nabble.com/Missing-filters-in-ITK-installation-tp7589640.html Sent from the ITK Insight Users mailing list archive at Nabble.com. From francois.budin at kitware.com Wed Feb 22 11:01:10 2017 From: francois.budin at kitware.com (Francois Budin) Date: Wed, 22 Feb 2017 11:01:10 -0500 Subject: [ITK-users] Missing filters in ITK installation In-Reply-To: <1487778221335-7589640.post@n2.nabble.com> References: <1487778221335-7589640.post@n2.nabble.com> Message-ID: Hello, These filters have been published as part of the Insight Journal article you referenced. However, no ITK remote module has been created to directly make them available in ITK. This means that currently one has to download the source code of these filters outside of the ITK source code. Additionally, these filters are not wrapped in Python. The source code would need to be updated (probably just reorganize the files to respect the expected folder structure) to allow these filters to be part of an ITK remote module and completed to create the Python wrapping. You could contact the authors of the paper to see if they are willing to do it, or you are also more than welcome to do it. It would be great to add this filter directly in ITK and I would gladly help you to get started. The ITK Software Guide (chapter 9) provides a lot of information on how to proceed to create an ITK module [1]. You can also look at filters that have an existing ITK remote module, such as [2]. Thank you for your help, Francois [1] https://itk.org/ITKSoftwareGuide/html/Book1/ITKSoftwareGuide-Book1.html [2] https://github.com/InsightSoftwareConsortium/ITKCuberille On Wed, Feb 22, 2017 at 10:43 AM, engineeringmath wrote: > Hello, > > I have been using SimpleITK for a while. But I recently needed filters that > were not available in SimpleITK, so I installed ITK. However, after > importing ITK into my python IDE, I see that those filters are not > available. Also, searching my computer I cannot find those filters. The > filters I am looking for are AverageOutwardFluxImageFilter and > MedialCurveImageFilter (please see the links below). > > Am I making a mistake during the installation? > > Your help is greatly appreciated. > > http://www.insight-journal.org/browse/publication/165 > http://www.dtic.upf.edu/~afrangi/articles/tij2007.pdf > > > > > -- > View this message in context: http://itk-insight-users. > 2283740.n2.nabble.com/Missing-filters-in-ITK-installation-tp7589640.html > Sent from the ITK Insight Users mailing list archive at Nabble.com. > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From matt.mccormick at kitware.com Wed Feb 22 11:39:15 2017 From: matt.mccormick at kitware.com (Matt McCormick) Date: Wed, 22 Feb 2017 11:39:15 -0500 Subject: [ITK-users] Filter working on both itk::Image and itk::VectorImage In-Reply-To: <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> Message-ID: Hi Cyril, Yes, this is a good approach. Thanks for sharing your investigation. Matt On Wed, Feb 22, 2017 at 5:52 AM, Cyril Mory wrote: > Answering my own question: > > I found a way to do what I needed using itk::NumericTraits : > > OutputImagePixelType pix; > itk::NumericTraits::SetLength(pix, > this->GetVectorLength()); > pix = itk::NumericTraits::OneValue(pix) * value; > > It works for both cases with the same code. However, if there is a better > way (cleaner, safer, more compact, ... whatever the wayin which it is > better), I'd be happy to learn about it. > > Best regards, > Cyril > > > On 22/02/2017 10:38, Cyril Mory wrote: >> >> Hi ITK users, >> >> I am writing an itk::ImageToImageFilter, and I want the filter to work >> with T=itk::Image as well as with T=itk::VectorImage. >> >> To set/get the vectorLength of an image (which is 1 for an itk::Image, and >> varies for an itk::VectorImage), I have successfully used the functions >> Set/GetNumberOfComponentsPerPixel from the itk::ImageBase class, which work >> for both itk::Image and itk::VectorImage. >> >> But I cannot find a way to initialize one of the pixels to a given value, >> that would work for both cases, i.e. whether that pixel is a scalar or a >> variableLengthVector. For now, the best I could do is define a function >> FillPixel in my filter, like this: >> >> OutputImagePixelType FillPixel(OutputImageInternalPixelType value) {return >> value;} >> >> and write a template specialization when my filter is instantiated with >> itk::VectorImage, like this: >> >> template <> >> itk::VariableLengthVector >> rtk::ConstantImageSource > >> ::FillPixel(float value) >> { >> itk::VariableLengthVector vect; >> vect.SetSize(this->GetVectorLength()); >> vect.Fill(value); >> return (vect); >> } >> >> Did I miss something ? Is there a better way of doing this in ITK ? >> >> Looking forward to reading you, >> Cyril >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users > > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users From cyril.mory at creatis.insa-lyon.fr Mon Feb 27 06:09:00 2017 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 27 Feb 2017 12:09:00 +0100 Subject: [ITK-users] Filter working on both itk::Image and itk::VectorImage In-Reply-To: References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> Message-ID: <07d017c1-cb58-28f7-0bd0-1e2250c3cf2e@creatis.insa-lyon.fr> Hi, Still the same topic, but a different issue: I have a filter that is templated over its image input type, usually itk::Image. I want to modify it so that it also works when that type is itk::VectorImage. This filter internally defines SliceType = itk::Image. But when processing an itk::VectorImage, I would like this SliceType to be itk::VectorImage. I don't think there is a way in C++ to recover the itk::Image<> or the itk::VectorImage<> "un-templated", and define a type with whole new template arguments. But is there an ITK mechanism that would solve my problem ? Best regards, Cyril On 22/02/2017 17:39, Matt McCormick wrote: > Hi Cyril, > > Yes, this is a good approach. Thanks for sharing your investigation. > > Matt > > On Wed, Feb 22, 2017 at 5:52 AM, Cyril Mory > wrote: >> Answering my own question: >> >> I found a way to do what I needed using itk::NumericTraits : >> >> OutputImagePixelType pix; >> itk::NumericTraits::SetLength(pix, >> this->GetVectorLength()); >> pix = itk::NumericTraits::OneValue(pix) * value; >> >> It works for both cases with the same code. However, if there is a better >> way (cleaner, safer, more compact, ... whatever the wayin which it is >> better), I'd be happy to learn about it. >> >> Best regards, >> Cyril >> >> >> On 22/02/2017 10:38, Cyril Mory wrote: >>> Hi ITK users, >>> >>> I am writing an itk::ImageToImageFilter, and I want the filter to work >>> with T=itk::Image as well as with T=itk::VectorImage. >>> >>> To set/get the vectorLength of an image (which is 1 for an itk::Image, and >>> varies for an itk::VectorImage), I have successfully used the functions >>> Set/GetNumberOfComponentsPerPixel from the itk::ImageBase class, which work >>> for both itk::Image and itk::VectorImage. >>> >>> But I cannot find a way to initialize one of the pixels to a given value, >>> that would work for both cases, i.e. whether that pixel is a scalar or a >>> variableLengthVector. For now, the best I could do is define a function >>> FillPixel in my filter, like this: >>> >>> OutputImagePixelType FillPixel(OutputImageInternalPixelType value) {return >>> value;} >>> >>> and write a template specialization when my filter is instantiated with >>> itk::VectorImage, like this: >>> >>> template <> >>> itk::VariableLengthVector >>> rtk::ConstantImageSource > >>> ::FillPixel(float value) >>> { >>> itk::VariableLengthVector vect; >>> vect.SetSize(this->GetVectorLength()); >>> vect.Fill(value); >>> return (vect); >>> } >>> >>> Did I miss something ? Is there a better way of doing this in ITK ? >>> >>> Looking forward to reading you, >>> Cyril >>> >>> _____________________________________ >>> 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://public.kitware.com/mailman/listinfo/insight-users >> >> _____________________________________ >> 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://public.kitware.com/mailman/listinfo/insight-users From cyril.mory at creatis.insa-lyon.fr Mon Feb 27 10:24:21 2017 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 27 Feb 2017 16:24:21 +0100 Subject: [ITK-users] Filter working on both itk::Image and itk::VectorImage In-Reply-To: <07d017c1-cb58-28f7-0bd0-1e2250c3cf2e@creatis.insa-lyon.fr> References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> <07d017c1-cb58-28f7-0bd0-1e2250c3cf2e@creatis.insa-lyon.fr> Message-ID: <57c3c8a0-65cf-87b3-7544-53768437bb28@creatis.insa-lyon.fr> I found some help outside this mailing list, so again, I'm answering my own question (I'll try not to make it a habit). There is a solution using C++11, and features derived from "Substitution failure is not an error". The following code does it. I've added quite a lot of comments, so it should be understandable. #include #include #include #include #include #include #include #include namespace itk { template class ITK_EXPORT SFINAETestFilter : public itk::ImageToImageFilter< TInputImage, TInputImage > { public: /** Standard class typedefs. */ typedef SFINAETestFilter Self; typedef itk::ImageToImageFilter Superclass; typedef itk::SmartPointer Pointer; typedef itk::SmartPointer ConstPointer; // Define the types that a slice can take, depending on whether TInputImage is an itk::Image or and itk::VectorImage typedef itk::Image ImageSliceType; typedef itk::VectorImage VectorImageSliceType; // Define SliceType // std::is_same::value is true is T1 and T2 are the same type, and false otherwise // std::conditional::type is T3 if B is true, T4 otherwise // The code checks if TInputImage::PixelType is an itk::VariableLengthVector. If so, it uses VectorImageSliceType as SliceType // Otherwise, it uses ImageSliceType as SliceType typedef typename std::conditional >::value, VectorImageSliceType, ImageSliceType>::type SliceType; /** Method for creation through the object factory */ itkNewMacro(Self); /** Run-time type information (and related methods). */ itkTypeMacro(SFINAETestFilter, ImageToImageFilter); /** Superclass typedefs. */ typedef typename Superclass::OutputImageRegionType OutputImageRegionType; typedef typename Superclass::OutputImagePointer OutputImagePointer; /** ImageDimension constants */ itkStaticConstMacro(InputImageDimension, unsigned int, TInputImage::ImageDimension); typename SliceType::Pointer GetSlice() { // Create the slice typename SliceType::Pointer firstSlice = SliceType::New(); // Determine its size typename TInputImage::RegionType largest = this->GetInput()->GetLargestPossibleRegion(); typename SliceType::RegionType region; typename SliceType::SizeType size; typename SliceType::IndexType index; for (unsigned int dim = 0; dim < SliceType::ImageDimension; dim++) { size[dim] = largest.GetSize()[dim]; index[dim] = largest.GetIndex()[dim]; } region.SetSize(size); region.SetIndex(index); // Allocate firstSlice->SetRegions(region); firstSlice->SetNumberOfComponentsPerPixel(this->GetInput()->GetNumberOfComponentsPerPixel()); firstSlice->Allocate(); // Fill itk::ImageRegionIterator sliceIt(firstSlice, region); itk::ImageRegionConstIterator inputIt(this->GetInput(), largest); while(!sliceIt.IsAtEnd()) { sliceIt.Set(inputIt.Get()); ++sliceIt; ++inputIt; } // Return return firstSlice; } }; } /* end namespace itk */ int main(){ typedef itk::Image ImageType; typedef itk::VectorImage VectorImageType; // With the itk::Image template typedef itk::SFINAETestFilter SFINAEWithImageType; typename SFINAEWithImageType::Pointer withImageType = SFINAEWithImageType::New(); typedef itk::ImageFileReader ImageReaderType; ImageReaderType::Pointer imageReader = ImageReaderType::New(); imageReader->SetFileName("image.mha"); imageReader->Update(); withImageType->SetInput(imageReader->GetOutput()); withImageType->GetSlice()->Print(std::cout); itk::Image::IndexType firstPixelIndex; firstPixelIndex.Fill(0); std::cout << withImageType->GetSlice()->GetPixel(firstPixelIndex) << std::endl; // With the itk::VectorImage template typedef itk::SFINAETestFilter SFINAEWithVectorImageType; typename SFINAEWithVectorImageType::Pointer withVectorImageType = SFINAEWithVectorImageType::New(); typedef itk::ImageFileReader VectorImageReaderType; VectorImageReaderType::Pointer vectorImageReader = VectorImageReaderType::New(); vectorImageReader->SetFileName("vectorImage.mha"); vectorImageReader->Update(); withVectorImageType->SetInput(vectorImageReader->GetOutput()); withVectorImageType->GetSlice()->Print(std::cout); std::cout << withVectorImageType->GetSlice()->GetPixel(firstPixelIndex) << std::endl; return EXIT_SUCCESS; } On 27/02/2017 12:09, Cyril Mory wrote: > Hi, > > Still the same topic, but a different issue: > > I have a filter that is templated over its image input type, usually > itk::Image. I want to modify it so that it also works when > that type is itk::VectorImage. > > This filter internally defines SliceType = > itk::Image. But when > processing an itk::VectorImage, I would like this SliceType to be > itk::VectorImage. > > I don't think there is a way in C++ to recover the itk::Image<> or the > itk::VectorImage<> "un-templated", and define a type with whole new > template arguments. But is there an ITK mechanism that would solve my > problem ? > > Best regards, > > Cyril > > On 22/02/2017 17:39, Matt McCormick wrote: >> Hi Cyril, >> >> Yes, this is a good approach. Thanks for sharing your investigation. >> >> Matt >> >> On Wed, Feb 22, 2017 at 5:52 AM, Cyril Mory >> wrote: >>> Answering my own question: >>> >>> I found a way to do what I needed using itk::NumericTraits : >>> >>> OutputImagePixelType pix; >>> itk::NumericTraits::SetLength(pix, >>> this->GetVectorLength()); >>> pix = itk::NumericTraits::OneValue(pix) * >>> value; >>> >>> It works for both cases with the same code. However, if there is a >>> better >>> way (cleaner, safer, more compact, ... whatever the wayin which it is >>> better), I'd be happy to learn about it. >>> >>> Best regards, >>> Cyril >>> >>> >>> On 22/02/2017 10:38, Cyril Mory wrote: >>>> Hi ITK users, >>>> >>>> I am writing an itk::ImageToImageFilter, and I want the filter >>>> to work >>>> with T=itk::Image as well as with T=itk::VectorImage. >>>> >>>> To set/get the vectorLength of an image (which is 1 for an >>>> itk::Image, and >>>> varies for an itk::VectorImage), I have successfully used the >>>> functions >>>> Set/GetNumberOfComponentsPerPixel from the itk::ImageBase class, >>>> which work >>>> for both itk::Image and itk::VectorImage. >>>> >>>> But I cannot find a way to initialize one of the pixels to a given >>>> value, >>>> that would work for both cases, i.e. whether that pixel is a scalar >>>> or a >>>> variableLengthVector. For now, the best I could do is define a >>>> function >>>> FillPixel in my filter, like this: >>>> >>>> OutputImagePixelType FillPixel(OutputImageInternalPixelType value) >>>> {return >>>> value;} >>>> >>>> and write a template specialization when my filter is instantiated >>>> with >>>> itk::VectorImage, like this: >>>> >>>> template <> >>>> itk::VariableLengthVector >>>> rtk::ConstantImageSource > >>>> ::FillPixel(float value) >>>> { >>>> itk::VariableLengthVector vect; >>>> vect.SetSize(this->GetVectorLength()); >>>> vect.Fill(value); >>>> return (vect); >>>> } >>>> >>>> Did I miss something ? Is there a better way of doing this in ITK ? >>>> >>>> Looking forward to reading you, >>>> Cyril >>>> >>>> _____________________________________ >>>> 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://public.kitware.com/mailman/listinfo/insight-users >>> >>> _____________________________________ >>> 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://public.kitware.com/mailman/listinfo/insight-users > From francois.budin at kitware.com Mon Feb 27 13:21:41 2017 From: francois.budin at kitware.com (Francois Budin) Date: Mon, 27 Feb 2017 13:21:41 -0500 Subject: [ITK-users] Filter working on both itk::Image and itk::VectorImage In-Reply-To: <57c3c8a0-65cf-87b3-7544-53768437bb28@creatis.insa-lyon.fr> References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> <07d017c1-cb58-28f7-0bd0-1e2250c3cf2e@creatis.insa-lyon.fr> <57c3c8a0-65cf-87b3-7544-53768437bb28@creatis.insa-lyon.fr> Message-ID: Hey Cyril, This is a good idea. If you want to keep it compatible without requiring C++11, you might be able to do so using the "EnableIf" functions that are implemented in ITK, following the same paradigm (SFINAE) than you found. hth, Francois On Mon, Feb 27, 2017 at 10:24 AM, Cyril Mory < cyril.mory at creatis.insa-lyon.fr> wrote: > I found some help outside this mailing list, so again, I'm answering my > own question (I'll try not to make it a habit). There is a solution using > C++11, and features derived from "Substitution failure is not an error". > The following code does it. I've added quite a lot of comments, so it > should be understandable. > > > > #include > #include > #include > #include > #include > #include > > #include > #include > > namespace itk > { > > template > class ITK_EXPORT SFINAETestFilter : > public itk::ImageToImageFilter< TInputImage, TInputImage > > { > public: > /** Standard class typedefs. */ > typedef SFINAETestFilter Self; > typedef itk::ImageToImageFilter Superclass; > typedef itk::SmartPointer Pointer; > typedef itk::SmartPointer ConstPointer; > > // Define the types that a slice can take, depending on whether > TInputImage is an itk::Image or and itk::VectorImage > typedef itk::Image TInputImage::ImageDimension - 1> ImageSliceType; > typedef itk::VectorImage TInputImage::ImageDimension - 1> VectorImageSliceType; > > // Define SliceType > // std::is_same::value is true is T1 and T2 are the same type, > and false otherwise > // std::conditional::type is T3 if B is true, T4 otherwise > // The code checks if TInputImage::PixelType is an > itk::VariableLengthVector. If so, it uses VectorImageSliceType as SliceType > // Otherwise, it uses ImageSliceType as SliceType > typedef typename std::conditional TInputImage::PixelType, > itk::VariableLengthVector > >::value, > VectorImageSliceType, > ImageSliceType>::type SliceType; > > /** Method for creation through the object factory */ > itkNewMacro(Self); > > /** Run-time type information (and related methods). */ > itkTypeMacro(SFINAETestFilter, ImageToImageFilter); > > /** Superclass typedefs. */ > typedef typename Superclass::OutputImageRegionType > OutputImageRegionType; > typedef typename Superclass::OutputImagePointer OutputImagePointer; > > /** ImageDimension constants */ > itkStaticConstMacro(InputImageDimension, unsigned int, > TInputImage::ImageDimension); > > typename SliceType::Pointer GetSlice() > { > // Create the slice > typename SliceType::Pointer firstSlice = SliceType::New(); > > // Determine its size > typename TInputImage::RegionType largest = this->GetInput()->GetLargestPo > ssibleRegion(); > typename SliceType::RegionType region; > typename SliceType::SizeType size; > typename SliceType::IndexType index; > for (unsigned int dim = 0; dim < SliceType::ImageDimension; dim++) > { > size[dim] = largest.GetSize()[dim]; > index[dim] = largest.GetIndex()[dim]; > } > region.SetSize(size); > region.SetIndex(index); > > // Allocate > firstSlice->SetRegions(region); > firstSlice->SetNumberOfComponentsPerPixel(this->GetInput()-> > GetNumberOfComponentsPerPixel()); > firstSlice->Allocate(); > > // Fill > itk::ImageRegionIterator sliceIt(firstSlice, region); > itk::ImageRegionConstIterator inputIt(this->GetInput(), > largest); > while(!sliceIt.IsAtEnd()) > { > sliceIt.Set(inputIt.Get()); > ++sliceIt; > ++inputIt; > } > > // Return > return firstSlice; > } > > }; > > } /* end namespace itk */ > > > int main(){ > > typedef itk::Image ImageType; > typedef itk::VectorImage VectorImageType; > > // With the itk::Image template > typedef itk::SFINAETestFilter SFINAEWithImageType; > typename SFINAEWithImageType::Pointer withImageType = > SFINAEWithImageType::New(); > typedef itk::ImageFileReader ImageReaderType; > ImageReaderType::Pointer imageReader = ImageReaderType::New(); > imageReader->SetFileName("image.mha"); > imageReader->Update(); > withImageType->SetInput(imageReader->GetOutput()); > withImageType->GetSlice()->Print(std::cout); > > itk::Image::IndexType firstPixelIndex; > firstPixelIndex.Fill(0); > std::cout << withImageType->GetSlice()->GetPixel(firstPixelIndex) << > std::endl; > > // With the itk::VectorImage template > typedef itk::SFINAETestFilter SFINAEWithVectorImageType; > typename SFINAEWithVectorImageType::Pointer withVectorImageType = > SFINAEWithVectorImageType::New(); > typedef itk::ImageFileReader VectorImageReaderType; > VectorImageReaderType::Pointer vectorImageReader = > VectorImageReaderType::New(); > vectorImageReader->SetFileName("vectorImage.mha"); > vectorImageReader->Update(); > withVectorImageType->SetInput(vectorImageReader->GetOutput()); > withVectorImageType->GetSlice()->Print(std::cout); > > std::cout << withVectorImageType->GetSlice()->GetPixel(firstPixelIndex) > << std::endl; > > return EXIT_SUCCESS; > > } > > > > On 27/02/2017 12:09, Cyril Mory wrote: > >> Hi, >> >> Still the same topic, but a different issue: >> >> I have a filter that is templated over its image input type, usually >> itk::Image. I want to modify it so that it also works when that >> type is itk::VectorImage. >> >> This filter internally defines SliceType = itk::Image> dim - 1>. But when processing an itk::VectorImage, I would like this >> SliceType to be itk::VectorImage> - 1>. >> >> I don't think there is a way in C++ to recover the itk::Image<> or the >> itk::VectorImage<> "un-templated", and define a type with whole new >> template arguments. But is there an ITK mechanism that would solve my >> problem ? >> >> Best regards, >> >> Cyril >> >> On 22/02/2017 17:39, Matt McCormick wrote: >> >>> Hi Cyril, >>> >>> Yes, this is a good approach. Thanks for sharing your investigation. >>> >>> Matt >>> >>> On Wed, Feb 22, 2017 at 5:52 AM, Cyril Mory >>> wrote: >>> >>>> Answering my own question: >>>> >>>> I found a way to do what I needed using itk::NumericTraits : >>>> >>>> OutputImagePixelType pix; >>>> itk::NumericTraits::SetLength(pix, >>>> this->GetVectorLength()); >>>> pix = itk::NumericTraits::OneValue(pix) * >>>> value; >>>> >>>> It works for both cases with the same code. However, if there is a >>>> better >>>> way (cleaner, safer, more compact, ... whatever the wayin which it is >>>> better), I'd be happy to learn about it. >>>> >>>> Best regards, >>>> Cyril >>>> >>>> >>>> On 22/02/2017 10:38, Cyril Mory wrote: >>>> >>>>> Hi ITK users, >>>>> >>>>> I am writing an itk::ImageToImageFilter, and I want the filter to >>>>> work >>>>> with T=itk::Image as well as with T=itk::VectorImage. >>>>> >>>>> To set/get the vectorLength of an image (which is 1 for an itk::Image, >>>>> and >>>>> varies for an itk::VectorImage), I have successfully used the functions >>>>> Set/GetNumberOfComponentsPerPixel from the itk::ImageBase class, >>>>> which work >>>>> for both itk::Image and itk::VectorImage. >>>>> >>>>> But I cannot find a way to initialize one of the pixels to a given >>>>> value, >>>>> that would work for both cases, i.e. whether that pixel is a scalar or >>>>> a >>>>> variableLengthVector. For now, the best I could do is define a function >>>>> FillPixel in my filter, like this: >>>>> >>>>> OutputImagePixelType FillPixel(OutputImageInternalPixelType value) >>>>> {return >>>>> value;} >>>>> >>>>> and write a template specialization when my filter is instantiated with >>>>> itk::VectorImage, like this: >>>>> >>>>> template <> >>>>> itk::VariableLengthVector >>>>> rtk::ConstantImageSource > >>>>> ::FillPixel(float value) >>>>> { >>>>> itk::VariableLengthVector vect; >>>>> vect.SetSize(this->GetVectorLength()); >>>>> vect.Fill(value); >>>>> return (vect); >>>>> } >>>>> >>>>> Did I miss something ? Is there a better way of doing this in ITK ? >>>>> >>>>> Looking forward to reading you, >>>>> Cyril >>>>> >>>>> _____________________________________ >>>>> 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://public.kitware.com/mailman/listinfo/insight-users >>>>> >>>> >>>> _____________________________________ >>>> 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://public.kitware.com/mailman/listinfo/insight-users >>>> >>> >> > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From blowekamp at mail.nih.gov Mon Feb 27 13:46:52 2017 From: blowekamp at mail.nih.gov (Lowekamp, Bradley (NIH/NLM/LHC) [C]) Date: Mon, 27 Feb 2017 18:46:52 +0000 Subject: [ITK-users] [ITK] Filter working on both itk::Image and itk::VectorImage In-Reply-To: <07d017c1-cb58-28f7-0bd0-1e2250c3cf2e@creatis.insa-lyon.fr> References: <41eb944a-306a-db60-de1f-7ad8414c3173@creatis.insa-lyon.fr> <6d96de7a-acc0-b62c-8fe5-6f3cc9e39455@creatis.insa-lyon.fr> <49fe2e35-b655-44bd-54f0-5949e5b1e926@creatis.insa-lyon.fr> <07d017c1-cb58-28f7-0bd0-1e2250c3cf2e@creatis.insa-lyon.fr> Message-ID: <91FCAC15-89FB-4F88-9AFC-A15FFF2D33E8@mail.nih.gov> Hello, Sorry I didn?t see this sooner. You want to look at the itk::Image::Rebind class. I created it for this exact purpose. [1] You can look at itkSmoothingRecursiveGaussianImageFilter.h for an example usage. HTH, Brad [1] https://itk.org/Doxygen/html/structitk_1_1Image_1_1Rebind.html > On Feb 27, 2017, at 6:09 AM, Cyril Mory wrote: > > Hi, > > Still the same topic, but a different issue: > > I have a filter that is templated over its image input type, usually itk::Image. I want to modify it so that it also works when that type is itk::VectorImage. > > This filter internally defines SliceType = itk::Image. But when processing an itk::VectorImage, I would like this SliceType to be itk::VectorImage. > > I don't think there is a way in C++ to recover the itk::Image<> or the itk::VectorImage<> "un-templated", and define a type with whole new template arguments. But is there an ITK mechanism that would solve my problem ? > > Best regards, > > Cyril > > On 22/02/2017 17:39, Matt McCormick wrote: >> Hi Cyril, >> >> Yes, this is a good approach. Thanks for sharing your investigation. >> >> Matt >> >> On Wed, Feb 22, 2017 at 5:52 AM, Cyril Mory >> wrote: >>> Answering my own question: >>> >>> I found a way to do what I needed using itk::NumericTraits : >>> >>> OutputImagePixelType pix; >>> itk::NumericTraits::SetLength(pix, >>> this->GetVectorLength()); >>> pix = itk::NumericTraits::OneValue(pix) * value; >>> >>> It works for both cases with the same code. However, if there is a better >>> way (cleaner, safer, more compact, ... whatever the wayin which it is >>> better), I'd be happy to learn about it. >>> >>> Best regards, >>> Cyril >>> >>> >>> On 22/02/2017 10:38, Cyril Mory wrote: >>>> Hi ITK users, >>>> >>>> I am writing an itk::ImageToImageFilter, and I want the filter to work >>>> with T=itk::Image as well as with T=itk::VectorImage. >>>> >>>> To set/get the vectorLength of an image (which is 1 for an itk::Image, and >>>> varies for an itk::VectorImage), I have successfully used the functions >>>> Set/GetNumberOfComponentsPerPixel from the itk::ImageBase class, which work >>>> for both itk::Image and itk::VectorImage. >>>> >>>> But I cannot find a way to initialize one of the pixels to a given value, >>>> that would work for both cases, i.e. whether that pixel is a scalar or a >>>> variableLengthVector. For now, the best I could do is define a function >>>> FillPixel in my filter, like this: >>>> >>>> OutputImagePixelType FillPixel(OutputImageInternalPixelType value) {return >>>> value;} >>>> >>>> and write a template specialization when my filter is instantiated with >>>> itk::VectorImage, like this: >>>> >>>> template <> >>>> itk::VariableLengthVector >>>> rtk::ConstantImageSource > >>>> ::FillPixel(float value) >>>> { >>>> itk::VariableLengthVector vect; >>>> vect.SetSize(this->GetVectorLength()); >>>> vect.Fill(value); >>>> return (vect); >>>> } >>>> >>>> Did I miss something ? Is there a better way of doing this in ITK ? >>>> >>>> Looking forward to reading you, >>>> Cyril >>>> >>>> _____________________________________ >>>> 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://public.kitware.com/mailman/listinfo/insight-users >>> >>> _____________________________________ >>> 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://public.kitware.com/mailman/listinfo/insight-users > > _____________________________________ > 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://public.kitware.com/mailman/listinfo/insight-users > _______________________________________________ > Community mailing list > Community at itk.org > http://public.kitware.com/mailman/listinfo/community