Ignore:
Timestamp:
Feb 26, 2008, 2:49:38 PM (14 years ago)
Author:
Markus Ringnér
Message:

Fixed #322

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/classifier/IGP.h

    r1120 r1158  
    5151 
    5252  public:
     53    ///
     54    /// Constructor taking the training data and the target vector and
     55    /// as input.
     56    ///
     57    IGP(const MatrixLookup&, const Target&);
     58
     59
    5360    ///
    5461    /// Constructor taking the training data, the target vector and
    5562    /// the distance measure as input.
    5663    ///
    57     IGP(const MatrixLookup&, const Target&);
     64    IGP(const MatrixLookup&, const Target&, const Distance&);
    5865
    5966    ///
     
    6976
    7077  private:
     78    void calculate();
     79
    7180    utility::Vector igp_;
    7281    Distance distance_;
     
    8392    : matrix_(data), target_(target)
    8493  {   
     94    calculate();
     95  }
     96
     97  template <typename Distance>
     98  IGP<Distance>::IGP(const MatrixLookup& data, const Target& target, const Distance& dist)
     99    : matrix_(data), target_(target), distance_(dist)
     100  {   
     101    calculate();
     102  }
     103
     104 
     105  template <typename Distance>
     106  IGP<Distance>::~IGP()   
     107  {
     108  }
     109
     110  template <typename Distance>
     111  void IGP<Distance>::calculate()
     112  {
    85113    utility::yat_assert<std::runtime_error>(target_.size()==matrix_.columns());
    86114   
     
    108136    }
    109137  }
    110  
    111   template <typename Distance>
    112   IGP<Distance>::~IGP()   
    113   {
    114   }
    115138
    116139 
Note: See TracChangeset for help on using the changeset viewer.