Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkIterativeSupervisedTrainingFunction.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkIterativeSupervisedTrainingFunction.h,v $
00005   Language:  C++
00006   Date:      $Date: 2009-01-24 21:33:49 $
00007   Version:   $Revision: 1.4 $
00008 
00009   Copyright (c) Insight Software Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even 
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 
00018 #ifndef __itkIterativeSupervisedTrainingFunction_h
00019 #define __itkIterativeSupervisedTrainingFunction_h
00020 
00021 #include "itkTrainingFunctionBase.h"
00022 
00023 
00024 namespace itk
00025 {
00026 namespace Statistics
00027 {
00028 
00029 template<class TSample, class TTargetVector, class ScalarType>
00030 class IterativeSupervisedTrainingFunction : public TrainingFunctionBase<TSample, TTargetVector, ScalarType>
00031 {
00032 public:
00033 
00034   typedef IterativeSupervisedTrainingFunction                      Self;
00035   typedef TrainingFunctionBase<TSample, TTargetVector, ScalarType> Superclass;
00036   typedef SmartPointer<Self>                                       Pointer;
00037   typedef SmartPointer<const Self>                                 ConstPointer;
00038 
00040   itkTypeMacro(IterativeSupervisedTrainingFunction, TrainingFunctionBase);
00041 
00043   itkNewMacro(Self);
00044 
00045   typedef typename Superclass::NetworkType        NetworkType;
00046   typedef typename Superclass::InternalVectorType InternalVectorType;
00047 
00048   void SetNumOfIterations(long i);
00049 
00050   virtual void Train(NetworkType* net, TSample* samples, TTargetVector* targets);
00051 
00052   itkSetMacro(Threshold, ScalarType);
00053 
00054 protected:
00055 
00056   IterativeSupervisedTrainingFunction();
00057   virtual ~IterativeSupervisedTrainingFunction(){};
00058   
00060   virtual void PrintSelf( std::ostream& os, Indent indent ) const;
00061 
00062   ScalarType m_Threshold;
00063   bool       m_Stop; //stop condition
00064 };
00065 
00066 } // end namespace Statistics
00067 } // end namespace itk
00068 
00069 #ifndef ITK_MANUAL_INSTANTIATION
00070   #include "itkIterativeSupervisedTrainingFunction.txx"
00071 #endif
00072 
00073 #endif
00074 

Generated at Sat Feb 28 12:52:36 2009 for ITK by doxygen 1.5.6 written by Dimitri van Heesch, © 1997-2000