[Insight-users] CovarianceCalculator

Lucas Lorenzo lucas at cvrti.utah.edu
Tue Jun 15 14:13:03 EDT 2004


Hi all,

I'm having a linking problem when compiling the following code (I'm 
including only the important parts):

#include "itkVector.h"
#include "itkListSample.h"
#include "itkCovarianceCalculator.h"

int main( int argc, char * argv[] )
{
  const unsigned int vsize = 60;
  typedef itk::Vector< float, vsize >  InputPixelType;

   typedef itk::Statistics::ListSample< InputPixelType > SampleType ;
   SampleType::Pointer sample = SampleType::New() ;

// here I create the samplelist

typedef itk::Statistics::CovarianceCalculator< SampleType >
CovarianceAlgorithmType;
CovarianceAlgorithmType::Pointer covarianceAlgorithm = 
CovarianceAlgorithmType::New();
covarianceAlgorithm->SetInputSample( sample );
// I've already calculated the mean:
covarianceAlgorithm->SetMean( meanAlgorithm->GetOutput() );
covarianceAlgorithm->Update();

return 0;
}

The error message looks as follows:

lucas:Seg_Code> make
Building dependencies cmake.check_depends...
Building object file ThresholdSegPrSh.o...
Building executable /private/var/automount/Seg_Code/ThresholdSegPrSh...
ld: Undefined symbols:
vnl_matrix_fixed<double, (unsigned)60, (unsigned)60>::div(double 
const*, double, double*)
vnl_matrix_fixed<double, (unsigned)60, (unsigned)60>::fill(double)
vnl_matrix_fixed<double, (unsigned)60, 
(unsigned)60>::print(std::basic_ostream<char, std::char_traits<char> 
 >&) const
make[1]: *** [/private/var/automount/Seg_Code/ThresholdSegPrSh] Error 1
make: *** [default_target] Error 2


Could anyone please help me with this problem ?
Thanks,

Lucas Lorenzo

University of Utah
Nora Eccles Harrison CardioVascular Research and Training Institute
Fellows Room
95 South 2000 East
Salt Lake City, UT 84112-5000

e-mail:  lucas at cvrti.utah.edu
telephone: 801-587-9536
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/enriched
Size: 2000 bytes
Desc: not available
Url : http://public.kitware.com/pipermail/insight-users/attachments/20040615/7c26b219/attachment.bin


More information about the Insight-users mailing list