Changeset 1108 for trunk/yat/classifier


Ignore:
Timestamp:
Feb 19, 2008, 6:40:59 PM (13 years ago)
Author:
Peter
Message:

adding svm copy constructor

Location:
trunk/yat/classifier
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/classifier/SVM.cc

    r1102 r1108  
    5656      trained_(false)
    5757  {
     58  }
     59
     60
     61  SVM::SVM(const SVM& other)
     62    : bias_(other.bias_), C_inverse_(other.C_inverse_), kernel_(NULL),
     63      margin_(0), max_epochs_(other.max_epochs_), tolerance_(other.tolerance_),
     64      trained_(other.trained_)
     65  {
     66    if (other.kernel_)
     67      kernel_ = new KernelLookup(*other.kernel_);
    5868  }
    5969
  • trunk/yat/classifier/SVM.h

    r1102 r1108  
    6161    SVM(void);
    6262
     63    /**
     64       Copy constructor.
     65    */
     66    SVM(const SVM&);
     67         
    6368    ///
    6469    /// Destructor
     
    184189  private:
    185190    ///
    186     /// Copy constructor. (not implemented)
    187     ///
    188     SVM(const SVM&);
    189          
    190     ///
    191191    /// Calculates bounds for alpha2
    192192    ///
Note: See TracChangeset for help on using the changeset viewer.