AUREA.heuristic.LearnerQueue
index
/home/earls3/Price/AUREA/build/lib.linux-x86_64-2.6/AUREA/heuristic/LearnerQueue.py

Copyright (C) 2011  N.D. Price Lab
 
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Affero General Public License for more details.
 
You should have received a copy of the GNU Affero General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

 
Modules
       
AUREA.learner.dirac
AUREA.learner.ktsp
time
AUREA.learner.tsp
AUREA.learner.tst

 
Classes
       
LearnerQueue

 
class LearnerQueue
     Methods defined here:
__init__(self, data_package, wilc_data_type='probe', weight=None, scale=None, minWeight=0.5)
This class generates a sequence of learner objects.
Inputs:
    req:
        data_package: provide an already set up packager.DataPackage object
    optional:
        wilc_data_type: should we use probes or genes to simulate the wilcoxon process in the TSx's
        weight: A list of weights that estimated times are divided by
        scale: A list of scaling factors for the complexity estimates.
        minWeight: a weight at which to normalize the weights.
__iter__(self)
feedback(self, learner_id, apparent_accuracy)
Adjusts the weights of a learner.
learner_id matching global data attribute
apparent_accuracy - percent accuracy of learner
genDirac(self, min_network_size, numTopNetworks, data_type='gene')
generates the pq for dirac.
inputs: 
    min_network_size: a tuple with (start, end, increment)
    numTopNetworks: a tuple with (start, end, increment)
genKTSP(self, maxK, ncv, nlo, r1, r2, equijoin=False, data_type='probe')
generates the pq for tst
inputs:
    maxK - tuple describing the range for the maximum k value
    ncv - tuple describing the range for number of cross validations
    nlo - tuple describing the range for number of elements to leave out of internal crossvalidation 
    r1 - tuple describing the range for filter 1 (from, to, increment)
    r2 - tuple describing the range for filter 2 (from, to, increment)
    equijoin - boolean, should we restrict filters to [10,10] [20,20] etc.
genTSP(self, r1, r2, equijoin=False, data_type='probe')
generates the pq for tsp.
inputs: 
    r1 - tuple describing the range for filter 1 (from, to, increment)
    r2 - tuple describing the range for filter 2 (from, to, increment)
    equijoin - boolean, should we restrict filters to [10,10] [20,20] etc.
genTST(self, r1, r2, r3, equijoin=False, data_type='probe')
generates the pq for tst
inputs: 
    r1 - tuple describing the range for filter 1 (from, to, increment)
    r2 - tuple describing the range for filter 2 (from, to, increment)
    r3 - tuple describing the range for filter 3 (from, to, increment)
    equijoin - boolean, should we restrict filters to [10,10] [20,20] etc.
getEstimatedTime(self, learner_id, complexity)
getLearner(self, settings)
Returns a learner object corresponding to the provided settings dict.
next(self)
trainLearner(self, settings, complexity)
Returns a learner that has been trained according to the settings given.

Data and other attributes defined here:
dirac = 0
ktsp = 3
tsp = 1
tst = 2