changeset 498:2be795cc5c3a

More documentation + todo
author Joseph Turian <turian@gmail.com>
date Tue, 28 Oct 2008 12:25:15 -0400
parents a272f4cbf004
children a419edf4e06c
files algorithms/layer.py algorithms/stacker.py
diffstat 2 files changed, 13 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/algorithms/layer.py	Tue Oct 28 12:25:15 2008 -0400
@@ -0,0 +1,9 @@
+"""
+@todo: Make a layer class, with standardized names:
+    input, cost, lr, and update
+(a Method called update, to be more precise, whose first argument is the input)
+
+Modules like pylearn.algorithms.logistic_regression.Module_Nclass and
+pylearn.algorithms.???.Bin_Regressor should inherit from Layer and
+Stacker should assume Layer.
+"""
--- a/algorithms/stacker.py	Tue Oct 28 12:25:04 2008 -0400
+++ b/algorithms/stacker.py	Tue Oct 28 12:25:15 2008 -0400
@@ -6,6 +6,7 @@
 
 class Stacker(T.RModule):
     """
+    @note: Assumes some names in the layers: input, cost, lr, and update
     @todo: Maybe compile functions on demand, rather than immediately.
     """
 
@@ -46,6 +47,9 @@
                                    for param in to_update),
                               list(all_kits)))
 
+#           @todo: Add diagnostics
+#             self.diagnose_from_input = Method([self.input], self.layers[0].diagnose.outputs + self.layers[1].diagnose.outputs ...
+
         self.local_update = local_update
         self.global_update = global_update
         self.update = self.global_update[-1]