changeset 1504:bf5c0f797161

Fix test.
author Frederic Bastien <nouiz@nouiz.org>
date Mon, 12 Sep 2011 10:48:33 -0400
parents 1ee532a6f33b
children 723e2d761985
files pylearn/algorithms/kernel_regression.py pylearn/algorithms/linear_regression.py
diffstat 2 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/pylearn/algorithms/kernel_regression.py	Mon Sep 12 10:24:24 2011 -0400
+++ b/pylearn/algorithms/kernel_regression.py	Mon Sep 12 10:48:33 2011 -0400
@@ -2,7 +2,7 @@
 Implementation of kernel regression:
 """
 
-from pylearn.old_dataset.learner import OfflineLearningAlgorithm
+#from pylearn.old_dataset.learner import OfflineLearningAlgorithm
 from theano import tensor as T
 from theano.tensor.nnet import prepend_1_to_each_row
 from theano.scalar import as_scalar
@@ -15,7 +15,7 @@
 # map a N-vector to a Nx1 matrix
 col_vector = theano.tensor.DimShuffle((False,),[0,'x'])
 
-class KernelRegression(OfflineLearningAlgorithm):
+class KernelRegression():#OfflineLearningAlgorithm):
     """
 Implementation of kernel regression:
 * the data are n (x_t,y_t) pairs and we want to estimate E[y|x]
--- a/pylearn/algorithms/linear_regression.py	Mon Sep 12 10:24:24 2011 -0400
+++ b/pylearn/algorithms/linear_regression.py	Mon Sep 12 10:48:33 2011 -0400
@@ -4,7 +4,7 @@
 the use of theano.
 """
 
-from pylearn.old_dataset.learner import OfflineLearningAlgorithm,OnlineLearningAlgorithm
+#from pylearn.old_dataset.learner import OfflineLearningAlgorithm,OnlineLearningAlgorithm
 from theano import tensor as T
 from theano.tensor.nnet import prepend_1_to_each_row
 from theano.scalar import as_scalar
@@ -12,7 +12,7 @@
 import theano
 import numpy
 
-class LinearRegression(OfflineLearningAlgorithm):
+class LinearRegression():#OfflineLearningAlgorithm):
     """
     Implement linear regression, with or without L2 regularization
     (the former is called Ridge Regression and the latter Ordinary Least Squares).
@@ -186,7 +186,7 @@
   return p.compute_outputs(inputs)
 
 #TODO : an online version
-class OnlineLinearRegression(OnlineLearningAlgorithm):
+class OnlineLinearRegression():#OnlineLearningAlgorithm):
     """
     Training can proceed sequentially (with multiple calls to update with
     different disjoint subsets of the training sets). After each call to