[Rtk-users] error in ThreeDCircularProjectionGeometry GeometryType

Simon Rit simon.rit at creatis.insa-lyon.fr
Tue Jun 25 04:50:15 EDT 2019


Hi Howard,
Since it's a linking problem, maybe you should check that you have linked
the RTK_libraries, see e.g.,
https://github.com/SimonRit/RTK/blob/master/examples/FirstReconstruction/CMakeLists.txt#L12
I can try to fix the problem if you provide a full example.
Simon

On Mon, Jun 24, 2019 at 9:45 PM Howard <lomahu at gmail.com> wrote:

> Hi,
>
> I was trying to play with the simple example to reconstruct a sphere
> from the RTK wiki page. The sample code:
>
>  // Projection matrices
>   unsigned int numberOfProjections = 360;
>   unsigned int firstAngle = 0;
>   unsigned int angularArc = 360;
>   unsigned int sid =  80; // source to isocenter distance in mm
>   unsigned int sdd = 160; // 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<numberOfProjections; noProj++) {
>       double angle = (float)firstAngle + (float)noProj * angularArc /
> (float)numberOfProjections;
>       geometry->AddProjection(sid, sdd, angle, isox, isoy);
>   }
>
>
> When I compiled the code, I got an error from the line in the projection
> loop:
>
> geometry->AddProjection(sid, sdd, angle, isox, isoy);
>
> I am using an old version of RTK 1.1 but it should not matter. Can
> anyone help me out? Thanks!
>
> [chaom02 at minerva2 recon]$ make
> Scanning dependencies of target Test1
> [ 50%] Building CXX object CMakeFiles/Test1.dir/Test1.cxx.o
> [100%] Linking CXX executable Test1
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::MatrixOffsetTransformBase<double, 3u,
> 3u>::GetFixedParameters() const':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZNK3itk25MatrixOffsetTransformBaseIdLj3ELj3EE18GetFixedParametersEv[_ZNK3itk25MatrixOffsetTransformBaseIdLj3ELj3EE18GetFixedParametersEv]+0x23):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::MatrixOffsetTransformBase<double, 3u,
> 3u>::SetFixedParameters(itk::OptimizerParameters<double> const&)':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk25MatrixOffsetTransformBaseIdLj3ELj3EE18SetFixedParametersERKNS_19OptimizerParametersIdEE[_ZN3itk25MatrixOffsetTransformBaseIdLj3ELj3EE18SetFixedParametersERKNS_19OptimizerParametersIdEE]+0x4f):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function
> `itk::CenteredEuler3DTransform<double>::SetParameters(itk::OptimizerParameters<double>
> const&)':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk24CenteredEuler3DTransformIdE13SetParametersERKNS_19OptimizerParametersIdEE[_ZN3itk24CenteredEuler3DTransformIdE13SetParametersERKNS_19OptimizerParametersIdEE]+0x31):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function
> `itk::Euler3DTransform<double>::SetParameters(itk::OptimizerParameters<double>
> const&)':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk16Euler3DTransformIdE13SetParametersERKNS_19OptimizerParametersIdEE[_ZN3itk16Euler3DTransformIdE13SetParametersERKNS_19OptimizerParametersIdEE]+0x40):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::Transform<double, 3u, 3u>::Transform(unsigned
> long)':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk9TransformIdLj3ELj3EEC2Em[_ZN3itk9TransformIdLj3ELj3EEC5Em]+0x49):
> undefined reference to `vnl_vector<double>::vnl_vector(unsigned int)'
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk9TransformIdLj3ELj3EEC2Em[_ZN3itk9TransformIdLj3ELj3EEC5Em]+0xa3):
> undefined reference to `vnl_vector<double>::vnl_vector(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::MatrixOffsetTransformBase<double, 3u,
> 3u>::MatrixOffsetTransformBase()':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk25MatrixOffsetTransformBaseIdLj3ELj3EEC2Ev[_ZN3itk25MatrixOffsetTransformBaseIdLj3ELj3EEC5Ev]+0x21b):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function
> `itk::Rigid3DTransform<double>::SetParameters(itk::OptimizerParameters<double>
> const&)':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk16Rigid3DTransformIdE13SetParametersERKNS_19OptimizerParametersIdEE[_ZN3itk16Rigid3DTransformIdE13SetParametersERKNS_19OptimizerParametersIdEE]+0x3e):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::MatrixOffsetTransformBase<double, 3u,
> 3u>::SetParameters(itk::OptimizerParameters<double> const&)':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZN3itk25MatrixOffsetTransformBaseIdLj3ELj3EE13SetParametersERKNS_19OptimizerParametersIdEE[_ZN3itk25MatrixOffsetTransformBaseIdLj3ELj3EE13SetParametersERKNS_19OptimizerParametersIdEE]+0x43):
> undefined reference to `vnl_vector<double>::set_size(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::MatrixOffsetTransformBase<double, 3u,
> 3u>::TransformVector(itk::VariableLengthVector<double> const&) const':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZNK3itk25MatrixOffsetTransformBaseIdLj3ELj3EE15TransformVectorERKNS_20VariableLengthVectorIdEE[_ZNK3itk25MatrixOffsetTransformBaseIdLj3ELj3EE15TransformVectorERKNS_20VariableLengthVectorIdEE]+0x2f):
> undefined reference to `vnl_vector<double>::vnl_vector(unsigned int)'
>
> /sc/orga/work/chaom02/usr/local/RTK/RTK-bin/bin/libRTK.a(rtkThreeDCircularProjectionGeometry.cxx.o):
> In function `itk::MatrixOffsetTransformBase<double, 3u,
> 3u>::TransformCovariantVector(itk::VariableLengthVector<double>
> const&) const':
>
> rtkThreeDCircularProjectionGeometry.cxx:(.text._ZNK3itk25MatrixOffsetTransformBaseIdLj3ELj3EE24TransformCovariantVectorERKNS_20VariableLengthVectorIdEE[_ZNK3itk25MatrixOffsetTransformBaseIdLj3ELj3EE24TransformCovariantVectorERKNS_20VariableLengthVectorIdEE]+0x3a):
> undefined reference to `vnl_vector<double>::vnl_vector(unsigned int)'
> collect2: error: ld returned 1 exit status
> make[2]: *** [Test1] Error 1
> make[1]: *** [CMakeFiles/Test1.dir/all] Error 2
> make: *** [all] Error 2
> _______________________________________________
> Rtk-users mailing list
> Rtk-users at public.kitware.com
> https://public.kitware.com/mailman/listinfo/rtk-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/rtk-users/attachments/20190625/4b5fd1d6/attachment.html>


More information about the Rtk-users mailing list