Ignore:
Timestamp:
08/08/13 17:21:29 (8 months ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Fixed an error in libsvm interface (example_to_svm function).

The 'index' did not get incremented in the presence of missing values.
I also cleaned up some old parameters, ...

File:
1 edited

Legend:

Unmodified
Added
Removed
  • source/orange/libsvm_interface.hpp

    r11607 r11650  
    103103 
    104104protected: 
    105     virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, float last=0.0, int type=0); 
     105    virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, double last=0.0); 
    106106    virtual svm_node* init_problem(svm_problem &problem, PExampleTable examples, int n_elements); 
    107107    virtual int getNumOfElements(PExampleGenerator examples); 
     
    115115    bool useNonMeta; //P include non meta attributes in the learning process 
    116116protected: 
    117     virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, float last=0.0, int type=0); 
     117    virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, double last=0.0); 
    118118    virtual int getNumOfElements(PExampleGenerator examples); 
    119119    virtual TSVMClassifier* createClassifier( 
     
    155155 
    156156protected: 
    157     virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, float last=0.0, int type=0); 
     157    virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, double last=0.0); 
    158158    virtual int getNumOfElements(const TExample& example); 
    159159 
     
    179179 
    180180protected: 
    181     virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, float last=0.0, int type=0); 
     181    virtual svm_node* example_to_svm(const TExample &ex, svm_node* node, double last=0.0); 
    182182    virtual int getNumOfElements(const TExample& example); 
    183183}; 
Note: See TracChangeset for help on using the changeset viewer.