From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From julien.jomier at kitware.com Wed Apr 1 08:47:31 2015 From: julien.jomier at kitware.com (Julien Jomier) Date: Wed, 1 Apr 2015 14:47:31 +0200 Subject: [Rtk-users] Hi rtk-users/developpers, In-Reply-To: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> References: <674041074.143852.1427706889580.JavaMail.zimbra@cppm.in2p3.fr> Message-ID: <551BE8E3.10903@kitware.com> Hi Mathieu, It's actually a little more complicated than just modifying the CMakeLists files, because we define a new image type itk::CudaImage which is not currently handled by the wrapping. We'll see if we can add this soon. Julien On 30/03/2015 11:14, Mathieu DUPONT wrote: > Hi rtk-users/developpers, > > > I want to use RTK in a python workflow, and for this I want to use CudaFDKConeBeamReconstructionFilter class. For this, I created a json file in "utilities/SimpleRTK/Code/BasicFilters/json" directory. I join this file with this email. But when I try to build, I get an error about "cuda.h" file missing. > > > " > [ 65%] Building CXX object Code/BasicFilters/src/CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o > cd /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src && /usr/bin/c++ -DSimpleRTKBasicFilters1_EXPORTS -DSimpleRTKBasicFilters_EXPORTS -fPIC -fPIC -I/data/mdupont/Compile/openrtk/bin-rtk -I/image/mdupont/soft/RTK/utilities/ITKCudaCommon/include -I/image/mdupont/soft/RTK/code -I/data/soft/include/ITK-4.7/Algorithms -I/data/soft/include/ITK-4.7 -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/Registration -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/IO/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/include -I/data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/Common/include -I/image/mdupont/soft/RTK/utilities/SimpleRTK/Code/BasicFilters/src -o CMakeFiles/SimpleRTKBasicFilters1.dir/srtkCudaFDKConeBeamReconstructionFilter.cxx.o -c /data/mdupont/Compile/openrtk/bin-rt k/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx > In file included from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImageDataManager.h:25, > from /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaImage.h:22, > from /image/mdupont/soft/RTK/code/rtkCudaFDKWeightProjectionFilter.h:25, > from /image/mdupont/soft/RTK/code/rtkCudaFDKConeBeamReconstructionFilter.h:23, > from /data/mdupont/Compile/openrtk/bin-rtk/SimpleRTK-build/Code/BasicFilters/src/srtkCudaFDKConeBeamReconstructionFilter.cxx:34: > /image/mdupont/soft/RTK/utilities/ITKCudaCommon/include/itkCudaUtil.h:33: fatal error: cuda.h: No such file or directory > " > > How to modify cmakelists files in order to use cuda classes with SimpleRTK ? > > Thanks for your help, > Mathieu Dupont > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > From bambykaa at yandex.ru Mon Apr 6 09:40:05 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 06 Apr 2015 19:40:05 +0600 Subject: [Rtk-users] geometry offsets Message-ID: <460241428327605@web13o.yandex.ru> Hello RTK users. Is there difference between this rtksimulatedgeometry -n 180 -o geometry.xml rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 and this rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt ? As i understand these sequences are identical and using for specifying detector offset. But if i want to specify iso center offset ? May be.. rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 --dimension 256 --phantomfile SheppLogan.txt Is it right ? From ieee.safdary at gmail.com Tue Apr 7 00:46:46 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 09:16:46 +0430 Subject: [Rtk-users] insert .dcm projection Message-ID: Hi, RTKuers I am use your command and I can read my .dcm projection for reconstruction without error but... when I see the projection in rtk format I am understand a big difference between original projection and rtk projection that shown in the following Please help me to resolve this problem thank you Good luck Safdari -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.png Type: image/png Size: 76505 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: rtk.png Type: image/png Size: 22044 bytes Desc: not available URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:26:38 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:26:38 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <460241428327605@web13o.yandex.ru> References: <460241428327605@web13o.yandex.ru> Message-ID: Hi, This is almost correct. I think the default origin is -127.5 in the second case so the option of the first case should have been "--origin=-27.5,-127.5". Then, there would have been no geometric difference for RTK, it comes down to a choice between shifting the origin of your image or setting a relative position of your image with respect to the volume. Note that if you have different offsets for each projection, only the second option is feasible. In RTK, the center-of-rotation is always (0,0,0). So you have to shift the rest if you want to shift it (source and detector position indeed). Simon On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 03:28:47 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 09:28:47 +0200 Subject: [Rtk-users] insert .dcm projection In-Reply-To: References: Message-ID: Sorry but your question is not clear. Please provide the original dicom projection and the command you use to produce your rtk.png image, then we might be able to explain. Simon On Tue, Apr 7, 2015 at 6:46 AM, safdary mohsen wrote: > Hi, RTKuers > I am use your command and I can read my .dcm projection for > reconstruction without error but... > when I see the projection in rtk format I am understand a big difference > between original projection and rtk projection that shown in the > following > Please help me to resolve this problem > > thank you > Good luck > Safdari > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ieee.safdary at gmail.com Tue Apr 7 09:17:02 2015 From: ieee.safdary at gmail.com (safdary mohsen) Date: Tue, 7 Apr 2015 17:47:02 +0430 Subject: [Rtk-users] insert .dcm Message-ID: Hi My code for Reconstruction is shown in the following this code work very well for .hnd and .his projection but when i insert .dcm projection, the output(reconstructed image) is black completely please solve this problem for me(10 .dcm projections and reconstructed image(just one slice) are attached to mail) int main(int , char **) { //// variable typedef itk::Image< float, 3 > ImageType; typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; ///////////////////////////////////////////////////////////////////////////////////////////////////// // Generate file names of projections itk::RegularExpressionSeriesFileNames::Pointer names = itk::RegularExpressionSeriesFileNames::New(); names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); names->SetRegularExpression(std::string(".*.dcm")); //// set projection file //////////////////////////////////////////////////////////////////////////////////////////////////// //// geometry // Defines the RTK geometry object typedef rtk::ThreeDCircularProjectionGeometry GeometryType; GeometryType::Pointer geometry = GeometryType::New(); // Projection matrices unsigned int numberOfProjections = 10; unsigned int firstAngle = 0; unsigned int angularArc = 360; unsigned int sid = 1000; // source to isocenter distance in mm unsigned int sdd = 1500; // source to detector distance in mm int isox = 0; // X coordinate on the projection image of isocenter int isoy = 0; // Y coordinate on the projection image of isocenter for(unsigned int noProj=0; noProjAddProjection(sid, sdd, angle, isox, isoy); } ///////////////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Projections reader typedef rtk::ProjectionsReader< ImageType > ReaderType; ReaderType::Pointer reader = ReaderType::New(); reader->SetFileNames(names->GetFileNames()); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create reconstructed image //////////////////////////////////// ConstantImageSourceType::Pointer constantImageSource = ConstantImageSourceType::New(); ConstantImageSourceType::PointType origin; ConstantImageSourceType::SpacingType spacing; ConstantImageSourceType::SizeType sizeOutput; origin[0] = -127.75;//12.875 origin[1] = -127.75;//30 origin[2] = -127.75;//12.875 // Adjust size according to geometry sizeOutput[0] = 512;//512 sizeOutput[1] = 512; sizeOutput[2] = 512; spacing[0] = .5;//.25 spacing[1] = .5; spacing[2] = .5; constantImageSource->SetOrigin( origin ); constantImageSource->SetSpacing( spacing ); constantImageSource->SetSize( sizeOutput ); constantImageSource->SetConstant( 0. ); ////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// std::cout << "Performing reconstruction" << std::endl; // FDK reconstruction filtering typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; FDKCPUType::Pointer feldkamp = FDKCPUType::New(); feldkamp->SetInput( 0, constantImageSource->GetOutput() ); feldkamp->SetInput( 1, reader->GetOutput()); feldkamp->SetGeometry( geometry); feldkamp->Update(); std::cout << "Writing output image" << std::endl; // Writer typedef itk::ImageFileWriter WriterType; WriterType::Pointer writer = WriterType::New(); writer->SetFileName( "output11.mha" );//mha //writer->SetUseCompression(true); writer->SetInput( feldkamp->GetOutput() ); writer->Update(); std::cout << "Done" << std::endl; return 0; } -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Tue Apr 7 12:37:31 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Tue, 7 Apr 2015 18:37:31 +0200 Subject: [Rtk-users] insert .dcm In-Reply-To: References: Message-ID: Dear Safdary, Thank you for sharing your code and the projections. I don't understand them either... I don't know where they are from and but they seem to be of very different nature. Image 1.dcm has air in black and object in white with pixel values between 0 and 255 while 49.dcm is the other way around. In any case, we won't figure it out for you, this is where we can't help you and you must figure it out yourself. It's a good thing that you did not manage to transfer the dicom files because they were not anonymized. Please be careful. Simon On Tue, Apr 7, 2015 at 3:17 PM, safdary mohsen wrote: > Hi > My code for Reconstruction is shown in the following > this code work very well for .hnd and .his projection but when i insert > .dcm projection, the output(reconstructed image) is black completely > please solve this problem for me(10 .dcm projections and reconstructed > image(just one slice) are attached to mail) > > > int main(int , char **) > { > > //// variable > typedef itk::Image< float, 3 > ImageType; > typedef rtk::ConstantImageSource< ImageType > ConstantImageSourceType; > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > // Generate file names of projections > itk::RegularExpressionSeriesFileNames::Pointer names = > itk::RegularExpressionSeriesFileNames::New(); > > names->SetDirectory(std::string("E://RTK/RTK-BUILD/bin/Debug/dcmprojection/")); > names->SetRegularExpression(std::string(".*.dcm")); > > //// set projection file > > //////////////////////////////////////////////////////////////////////////////////////////////////// > //// geometry > // Defines the RTK geometry object > typedef rtk::ThreeDCircularProjectionGeometry GeometryType; > GeometryType::Pointer geometry = GeometryType::New(); > > // Projection matrices > unsigned int numberOfProjections = 10; > unsigned int firstAngle = 0; > unsigned int angularArc = 360; > unsigned int sid = 1000; // source to isocenter distance in mm > unsigned int sdd = 1500; // source to detector distance in mm > int isox = 0; // X coordinate on the projection image of isocenter > int isoy = 0; // Y coordinate on the projection image of isocenter > > for(unsigned int noProj=0; noProj { > double angle = (float)firstAngle + (float)noProj * angularArc / > (float)numberOfProjections; > geometry->AddProjection(sid, > sdd, > angle, > isox, > isoy); > } > > > ///////////////////////////////////////////////////////////////////////////////////////////////////// > > /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Projections reader > > typedef rtk::ProjectionsReader< ImageType > ReaderType; > ReaderType::Pointer reader = ReaderType::New(); > reader->SetFileNames(names->GetFileNames()); > > > //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > // Create reconstructed image > //////////////////////////////////// > > ConstantImageSourceType::Pointer constantImageSource = > ConstantImageSourceType::New(); > ConstantImageSourceType::PointType origin; > ConstantImageSourceType::SpacingType spacing; > ConstantImageSourceType::SizeType sizeOutput; > > origin[0] = -127.75;//12.875 > origin[1] = -127.75;//30 > origin[2] = -127.75;//12.875 > > // Adjust size according to geometry > sizeOutput[0] = 512;//512 > sizeOutput[1] = 512; > sizeOutput[2] = 512; > > spacing[0] = .5;//.25 > spacing[1] = .5; > spacing[2] = .5; > > constantImageSource->SetOrigin( origin ); > constantImageSource->SetSpacing( spacing ); > constantImageSource->SetSize( sizeOutput ); > constantImageSource->SetConstant( 0. ); > > ////////////////////////////////////// > ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// > > std::cout << "Performing reconstruction" << std::endl; > // FDK reconstruction filtering > typedef rtk::FDKConeBeamReconstructionFilter< ImageType> FDKCPUType; > FDKCPUType::Pointer feldkamp = FDKCPUType::New(); > feldkamp->SetInput( 0, constantImageSource->GetOutput() ); > feldkamp->SetInput( 1, reader->GetOutput()); > feldkamp->SetGeometry( geometry); > feldkamp->Update(); > > std::cout << "Writing output image" << std::endl; > > // Writer > typedef itk::ImageFileWriter WriterType; > WriterType::Pointer writer = WriterType::New(); > writer->SetFileName( "output11.mha" );//mha > //writer->SetUseCompression(true); > writer->SetInput( feldkamp->GetOutput() ); > writer->Update(); > > std::cout << "Done" << std::endl; > return 0; > } > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bambykaa at yandex.ru Wed Apr 8 04:32:03 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Wed, 08 Apr 2015 14:32:03 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> Message-ID: <2787361428481923@web11g.yandex.ru> An HTML attachment was scrubbed... URL: From audrius at tomographix.com Thu Apr 9 03:22:39 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Thu, 09 Apr 2015 03:22:39 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <1427733860.932947.247117745.0F970FF8@webmail.messagingengine.com> <1427740117.962166.247173177.5170874A@webmail.messagingengine.com> <551AAC95.4060109@creatis.insa-lyon.fr> <1427855142.1506829.247864673.78C868B1@webmail.messagingengine.com> Message-ID: <1428564159.3626751.251122497.6243C67C@webmail.messagingengine.com> Hi Cyril, On Tue, Mar 31, 2015, at 22:25, Audrius Stundzia wrote: > > Hi Cyril, > > On Tue, Mar 31, 2015, at 09:17, Cyril Mory wrote: >> Hi Audrius, >> >> The release version 1.0.0 is already a bit old, and much has been improved since then. >> Could you use the git repository to download the most up-to-date version of RTK, and let us know whether you experience the same issues ? > > Thank you for your suggestion. I will do so and let you know. Sorry for the delay in my reply. Was addressing another shared lib bug in ITK CMake. I've now downloaded RTK rom the git repository and tried to build what I think is the most up-to-date version with. OS: Windows 8.1 x64 CUDA: 7.0 IDE: MS VS 2010 ITK: 4.7.1 [with 2 new CMake patches for shared libs] After having done so, I'm experiencing a different set of CUDA errors of the type >f:\program files\rtk\rtk-1.0.0\code\rtkCudaUtilities.hcu(49): error > C2664: 'fminf' : cannot convert parameter 1 from 'float' to 'float3' 6> No constructor could take the source type, or constructor overload resolution was ambiguous inline __host__ __device__ float3 fminf(float3 a, float3 b) { return make_float3(fminf(a.x,b.x), fminf(a.y,b.y), fminf(a.z,b.z)); } If you would please advise. Thank you. Regards, Audrius > >> >> If so, we will try to reproduce your compilation error, but since we have neither Windows 8.1 nor Visual Studio, we might not be able to obtain it at all. > > Understood. > > Best regards, > > Audrius > >> >> Best regards, Cyril >> >> On 03/30/2015 08:28 PM, Audrius Stundzia wrote: >>> >>> Hi Simon, >>> >>> On Mon, Mar 30, 2015, at 11:56, Simon Rit wrote: >>>> Alright but did you also check that the Debug version of ITK is built? >>> >>> Yes, I did do so. >>> >>> In my case it is installed in "F:\Program Files\itk\Debug" >>> >>>> >>>> If yes, then it's probably one of this shared lib issue with Windows, we'll try to fix it... >>> >>> Thank you. >>> >>> Regards, >>> >>> Audrius >>> >>>> >>>> On Mon, Mar 30, 2015 at 6:44 PM, Audrius Stundzia >>>> wrote: >>>>> >>>>> Hi Simon, >>>>> >>>>> Thank you for your prompt response. >>>>> >>>>> >>>>> On Mon, Mar 30, 2015, at 11:22, Simon Rit wrote: >>>>>> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >>>>> >>>>> >>>>> Yes, that was my first thought, so I double-checked that Build_Shared_Libs was set to "On" for both ITK and RTK. >>>>> >>>>> Regards, >>>>> >>>>> >>>>> Audrius >>>>> >>>>> >>>>>> Simon >>>>>> >>>>>> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>>>>>> Hello, >>>>>>> >>>>>>> OS: Windows 8.1 x64 >>>>>>> IDE: Visual Studio 2010 x64 >>>>>>> ITK: 4.7.1 >>>>>>> RTK: 1.0.0 >>>>>>> >>>>>>> The build in Release mode proceeds without any failures. Thank you. >>>>>>> >>>>>>> However, in Debug mode, the following link error occurs when building >>>>>>> the RTK project rtkcuda: >>>>>>> >>>>>>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>>>>>> itk::Matrix,class std::allocator>>>>>> itk::Matrix > > const & __cdecl >>>>>>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>>>>>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>>>>>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>>>>>> >>>>>>> Any insight as to how to deal with this link error would be appreciated. >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> Audrius >>>>>>> _______________________________________________ >>>>>>> Rtk-users mailing list >>>>>>> Rtk-users at public.kitware.com >>>>>>> http://public.kitware.com/mailman/listinfo/rtk-users >>>>>> >>>>> >>>>> >>>> >>> >>> >>> >>> _______________________________________________ Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From simon.rit at creatis.insa-lyon.fr Mon Apr 13 02:50:33 2015 From: simon.rit at creatis.insa-lyon.fr (Simon Rit) Date: Mon, 13 Apr 2015 08:50:33 +0200 Subject: [Rtk-users] geometry offsets In-Reply-To: <2787361428481923@web11g.yandex.ru> References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: Hi, I'm afraid it's in your hands from here, at least I won't have time to download and reconstruct your dataset. I don't understand the computation of the offset in the proj_sub.mhd file. Shouldn't it be -1 * (512 * 0.0957 - 0.0957) / 2 -1 *(500 * 0.096 - 0.096) / 2 0 ? Simon On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: > Ok. But i still have problems with reconstruction. Could you check me > please... > My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center > offset approximately calculated from projection 0.71775, gantry, 100 shots, > 1 degree for each shot. > camera: 1024x1000, pixel sizes 95.7um x 96um > > Firstly i converted all tif files to mhd via rtksubselect. Then: > rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 > --sid=327.3 --proj_iso_x=-0.71775 --source_x=-0.71775 > rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension > 512,512,512 --spacing 0.0957,0.096,0.0957 > > proj_sub.mhd: > ObjectType = Image > NDims = 3 > BinaryData = True > BinaryDataByteOrderMSB = False > CompressedData = False > TransformMatrix = 1 0 0 0 1 0 0 0 1 > Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / > 2) -1 *(500 * 0.096 - 0.096 / 2) 0 > CenterOfRotation = 0 0 0 > AnatomicalOrientation = RAI > ElementSpacing = 0.0957 0.096 1 > DimSize = 1024 1000 100 > ElementType = MET_FLOAT > ElementDataFile = proj_sub.raw > > Here is the raw file and few origin tifs : > https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing > https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing > > Volume is not as promising at all. Probably some geometry information in > this tomography system is incorrect, its just in development. (may be > central ray is not intersecting in the center of detector, and etc ). And of > course it can be cause of reconstruction problems. But, if suppose that > information above is correct, is i specify it right ? > > > 07.04.2015, 13:26, "Simon Rit" : > > Hi, > This is almost correct. I think the default origin is -127.5 in the second > case so the option of the first case should have been > "--origin=-27.5,-127.5". Then, there would have been no geometric difference > for RTK, it comes down to a choice between shifting the origin of your image > or setting a relative position of your image with respect to the volume. > Note that if you have different offsets for each projection, only the second > option is feasible. > > In RTK, the center-of-rotation is always (0,0,0). So you have to shift the > rest if you want to shift it (source and detector position indeed). > Simon > > On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: > > Hello RTK users. > Is there difference between this > rtksimulatedgeometry -n 180 -o geometry.xml > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 > > and this > > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > > ? > > As i understand these sequences are identical and using for specifying > detector offset. > > But if i want to specify iso center offset ? May be.. > rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 > rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 > --dimension 256 --phantomfile SheppLogan.txt > Is it right ? > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From bambykaa at yandex.ru Mon Apr 13 04:23:38 2015 From: bambykaa at yandex.ru (bambykaa 1) Date: Mon, 13 Apr 2015 14:23:38 +0600 Subject: [Rtk-users] geometry offsets In-Reply-To: References: <460241428327605@web13o.yandex.ru> <2787361428481923@web11g.yandex.ru> Message-ID: <752481428913418@web16g.yandex.ru> Hi, hovewer i think that origin in common cases (central ray intersects detector's plane at the center ) calculates as -1 * (W / 2 - SPACING / 2), so my W: 1024 - > -1 * (512 * 0.0957 - 0.0957 / ?2) anyway i have good volumes from another tomographs, the difference is that isocenter not at the center of xray and detector okay i will investigate my problem and keep you informed if i will make some progresses 13.04.2015, 12:50, "Simon Rit" : > Hi, > I'm afraid it's in your hands from here, at least I won't have time to > download and reconstruct your dataset. I don't understand the > computation of the offset in the proj_sub.mhd file. Shouldn't it be > -1 * (512 * 0.0957 - 0.0957) / 2 ?-1 *(500 * 0.096 - 0.096) / 2 0 > ? > Simon > > On Wed, Apr 8, 2015 at 10:32 AM, bambykaa 1 wrote: >> ?Ok. But i still have problems with reconstruction. Could you check me >> ?please... >> ?My geomerty: source to detector 396.8 mm, source to iso 327.3 mm, iso center >> ?offset approximately calculated from projection 0.71775, gantry, 100 shots, >> ?1 degree for each shot. >> ?camera: 1024x1000, ?pixel sizes 95.7um x 96um >> >> ?Firstly i converted all tif files to mhd via rtksubselect. Then: >> ?rtksimulatedgeometry -o geometry.xml --n 100 --arc=100 --sdd=396.8 >> ?--sid=327.3 ?--proj_iso_x=-0.71775 --source_x=-0.71775 >> ?rtkfdk -p . -r proj_sub.mhd -o fdk.mha -g geometry.xml --verbose --dimension >> ?512,512,512 --spacing 0.0957,0.096,0.0957 >> >> ?proj_sub.mhd: >> ?ObjectType = Image >> ?NDims = 3 >> ?BinaryData = True >> ?BinaryDataByteOrderMSB = False >> ?CompressedData = False >> ?TransformMatrix = 1 0 0 0 1 0 0 0 1 >> ?Offset = -48.95055 -47.952 0 < ---- i calc so: -1 * (512 * 0.0957 - 0.0957 / >> ?2) ?-1 *(500 * 0.096 - 0.096 / 2) 0 >> ?CenterOfRotation = 0 0 0 >> ?AnatomicalOrientation = RAI >> ?ElementSpacing = 0.0957 0.096 1 >> ?DimSize = 1024 1000 100 >> ?ElementType = MET_FLOAT >> ?ElementDataFile = proj_sub.raw >> >> ?Here is the raw file and few origin tifs : >> ?https://drive.google.com/file/d/0B9EY8AokXE8zbjdtUUQtVkFuM1U/view?usp=sharing >> ?https://drive.google.com/file/d/0B9EY8AokXE8zVi1RaDA2QzBwdDA/view?usp=sharing >> >> ?Volume is not as promising at all. ?Probably some geometry information in >> ?this tomography system is incorrect, its just in development. (may be >> ?central ray is not intersecting in the center of detector, and etc ). And of >> ?course it can be cause of reconstruction problems. But, if suppose that >> ?information above is correct, is i specify it right ? >> >> ?07.04.2015, 13:26, "Simon Rit" : >> >> ?Hi, >> ?This is almost correct. I think the default origin is -127.5 in the second >> ?case so the option of the first case should have been >> ?"--origin=-27.5,-127.5". Then, there would have been no geometric difference >> ?for RTK, it comes down to a choice between shifting the origin of your image >> ?or setting a relative position of your image with respect to the volume. >> ?Note that if you have different offsets for each projection, only the second >> ?option is feasible. >> >> ?In RTK, the center-of-rotation is always (0,0,0). So you have to shift the >> ?rest if you want to shift it (source and detector position indeed). >> ?Simon >> >> ?On Mon, Apr 6, 2015 at 3:40 PM, bambykaa 1 wrote: >> >> ?Hello RTK users. >> ?Is there difference between this >> ?rtksimulatedgeometry -n 180 -o geometry.xml >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt --origin=-28,-128 >> >> ?and this >> >> ?rtksimulatedgeometry -n 180 -o geometry.xml ?--proj_iso_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> >> ?? >> >> ?As i understand these sequences are identical and using for specifying >> ?detector offset. >> >> ?But if i want to specify iso center offset ? May be.. >> ?rtksimulatedgeometry -n 180 -o geometry.xml --proj_iso_x=100 --source_x=100 >> ?rtkprojectgeometricphantom -g geometry.xml -o projections.mha --spacing 1 >> ?--dimension 256 --phantomfile SheppLogan.txt >> ?Is it right ? >> ?_______________________________________________ >> ?Rtk-users mailing list >> ?Rtk-users at public.kitware.com >> ?http://public.kitware.com/mailman/listinfo/rtk-users From infrombox at yandex.ru Mon Apr 13 07:43:57 2015 From: infrombox at yandex.ru (1 1) Date: Mon, 13 Apr 2015 18:43:57 +0700 Subject: [Rtk-users] artifacts around high consistence small elements Message-ID: <1143501428925437@web26h.yandex.ru> Hi RTK users. I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi On volume i see artifacts in the form of luminescence and holes around elements. one of projections: http://i.imgur.com/iFesZ3o.png slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png what do you think may affect on them ? may be : - decrease rotation step, increase full rotation from 192 (in my case) to 360 - detector with higher dpi ? probably there is necessary apply some filter ? These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. thank you From cyril.mory at creatis.insa-lyon.fr Mon Apr 13 08:00:20 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Mon, 13 Apr 2015 14:00:20 +0200 Subject: [Rtk-users] artifacts around high consistence small elements In-Reply-To: <1143501428925437@web26h.yandex.ru> References: <1143501428925437@web26h.yandex.ru> Message-ID: <552BAFD4.3050003@creatis.insa-lyon.fr> Hi, Unfortunately, you are facing a problem, called "Metal artifact reduction", that is still a topic of active research. That means there is no easy off-the-shelf answer to your question. You could try : - other reconstruction algorithms available in RTK, especially rtksart or rtkconjugategradient - increasing the number of projections (it never hurts) but keep in mind that it will probably have only a limited impact. Or you can try implementing some known metal artifact reduction method in RTK (obviously this would take time, but on the bright side, you would learn how to code in RTK ! And we can provide help if you choose this path). The following presentation should help you familiarize with the topic: http://isssma2013.sciencesconf.org/conference/isssma2013/pages/Paris4june2013_jn2.ppt Best regards, Cyril On 04/13/2015 01:43 PM, 1 1 wrote: > Hi RTK users. > I try reconstruct such object: plasticine with implantation of high consistence ( lead, Pb ) elements about 50-150 um > Acquisition configuration: sdd: 344.1mm, sid: 344.1, shots: 640, rotation step: 0.3 deg, 1000x666, 700 dpi > On volume i see artifacts in the form of luminescence and holes around elements. > > one of projections: http://i.imgur.com/iFesZ3o.png > slices that demonstrate artifacts: http://i.imgur.com/RQExMO2.png, http://i.imgur.com/Th2fxzA.png > > what do you think may affect on them ? may be : > - decrease rotation step, increase full rotation from 192 (in my case) to 360 > - detector with higher dpi > ? > > probably there is necessary apply some filter ? > > These artifacts present not only in RTK, but other reconstruction software gives the same result. I dont beleive that its impossible to reconstruct such elements without artifacts, but i don't know the way where to investigate the problem. > > thank you > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users From cyril.mory at creatis.insa-lyon.fr Thu Apr 16 03:54:12 2015 From: cyril.mory at creatis.insa-lyon.fr (Cyril Mory) Date: Thu, 16 Apr 2015 09:54:12 +0200 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> Message-ID: <552F6AA4.7070902@creatis.insa-lyon.fr> Hi Audrius, I know you have moved on since then, but I answer nevertheless. Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Regards, Cyril On 03/30/2015 06:22 PM, Simon Rit wrote: > Hi, > No clue... Have you also compiled ITK in Debug mode with the same > library setting (dynamic or shared)? This is required as far as I know. > Simon > > On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia > > wrote: > > Hello, > > OS: Windows 8.1 x64 > IDE: Visual Studio 2010 x64 > ITK: 4.7.1 > RTK: 1.0.0 > > The build in Release mode proceeds without any failures. Thank you. > > However, in Debug mode, the following link error occurs when building > the RTK project rtkcuda: > > 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector itk::Matrix,class std::allocator itk::Matrix > > const & __cdecl > rtk::ProjectionGeometry<3>::GetMatrices(void)" > (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) > already defined in rtkCudaFDKBackProjectionImageFilter.obj > > Any insight as to how to deal with this link error would be > appreciated. > > Regards, > > Audrius > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users > > > > > _______________________________________________ > Rtk-users mailing list > Rtk-users at public.kitware.com > http://public.kitware.com/mailman/listinfo/rtk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: From audrius at tomographix.com Wed Apr 22 02:27:23 2015 From: audrius at tomographix.com (Audrius Stundzia) Date: Wed, 22 Apr 2015 02:27:23 -0400 Subject: [Rtk-users] RTK | Debug build link error In-Reply-To: <552F6AA4.7070902@creatis.insa-lyon.fr> References: <1427727231.336967.247063521.4F44D50F@webmail.messagingengine.com> <552F6AA4.7070902@creatis.insa-lyon.fr> Message-ID: <1429684043.1664841.256976753.63E4B242@webmail.messagingengine.com> Hi Cyril, Thank you for your reply and detailed explanation. On Thu, Apr 16, 2015, at 03:54, Cyril Mory wrote: > Hi Audrius, > > I know you have moved on since then, but I answer nevertheless. > Compiling on Windows 7 SP1, VS Community, with up-to-date RTK and ITK 4.7.1, in Debug and Shared Libs, I have experienced this same issue. > A temporary fix is to add "__declspec(dllexport)" to the rtkProjectionGeometry class declaration in rtkProjectionGeometry.h. > It should be equivalent to adding "RTK_EXPORT", but it currently isn't: there seems to be a problem in the way the macro RTK_EXPORT is interpreted. We are working on finding a solution to this problem. Understood. Thank you for your work in finding a solution. Regards, Audrius > > Regards, > Cyril > > On 03/30/2015 06:22 PM, Simon Rit wrote: >> Hi, No clue... Have you also compiled ITK in Debug mode with the same library setting (dynamic or shared)? This is required as far as I know. >> Simon >> >> On Mon, Mar 30, 2015 at 4:53 PM, Audrius Stundzia wrote: >>> Hello, >>> >>> OS: Windows 8.1 x64 >>> IDE: Visual Studio 2010 x64 >>> ITK: 4.7.1 >>> RTK: 1.0.0 >>> >>> The build in Release mode proceeds without any failures. Thank you. >>> >>> However, in Debug mode, the following link error occurs when building >>> the RTK project rtkcuda: >>> >>> 1>RTK.lib(RTK.dll) : error LNK2005: "public: class std::vector>> itk::Matrix,class std::allocator>> itk::Matrix > > const & __cdecl >>> rtk::ProjectionGeometry<3>::GetMatrices(void)" >>> (?GetMatrices@?$ProjectionGeometry@$02 at rtk@@QEAAAEBV?$vector at V?$Matrix at N$02$03 at itk@@V?$allocator at V?$Matrix at N$02$03 at itk@@@std@@@std@@XZ) >>> already defined in rtkCudaFDKBackProjectionImageFilter.obj >>> >>> Any insight as to how to deal with this link error would be appreciated. >>> >>> Regards, >>> >>> Audrius >>> _______________________________________________ >>> Rtk-users mailing list >>> Rtk-users at public.kitware.com >>> http://public.kitware.com/mailman/listinfo/rtk-users >> >> >> >> _______________________________________________ Rtk-users mailing list >> Rtk-users at public.kitware.com >> http://public.kitware.com/mailman/listinfo/rtk-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: