Package ml :: Module learner
[hide private]
[frames] | no frames]

Source Code for Module ml.learner

 1  ''' 
 2  It provides a general classifier API which unifies common  
 3  machine learning functions 
 4   
 5  Created on 19 Apr 2013 
 6   
 7  @author: Eleftherios Avramidis 
 8  ''' 
 9   
10   
11   
12 -def forname(name, library='orange', **kwargs):
13 """ 14 Wrap the specified external classifier into the generic 15 classifier class and return the object 16 @param name: the name of the classifier 17 @param library: the name of the library whose classifeir should be used 18 """ 19 pass
20 21 22
23 -class Regressor(object):
24 - def __init__(self, object):
25 pass
26
27 - def load_training_dataset(self, dataset, 28 class_name, 29 desired_parallel_attributes = [], 30 desired_source_attributes = [], 31 desired_target_attributes = [], 32 meta_attributes = [], 33 scale=True):
34 raise NotImplementedError();
35
36 - def feature_selection(self, config):
37 raise NotImplementedError();
38 39
40 - def set_learning_method(self, config):
41 raise NotImplementedError();
42 43
44 - def cross_validate_scores(self):
45 if not self.training_data_loaded: 46 raise AssertionError("Training data must be loaded, before cross validation") 47 self.cross_validate_start();
48
49 - def train(self):
50 self.train_start(self)
51
52 - def test_dataset(self):
53 raise NotImplementedError();
54
55 - def predict_dataset(self):
56 raise NotImplementedError();
57 58
59 -class Classifier(object):
60 ''' 61 classdocs 62 ''' 63 64
65 - def __init__(self, object):
66 ''' 67 Constructor 68 ''' 69 pass
70