changeset 1179:67f4edabb0cc

Merged
author Olivier Delalleau <delallea@iro>
date Fri, 17 Sep 2010 16:23:51 -0400
parents 10bc5ebb5823 (current diff) b699d096e6cc (diff)
children 9ebd40d31a1b
files doc/v2_planning/API_coding_style.txt doc/v2_planning/coding_style.txt
diffstat 6 files changed, 22 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/doc/index.txt	Fri Sep 17 16:21:55 2010 -0400
+++ b/doc/index.txt	Fri Sep 17 16:23:51 2010 -0400
@@ -27,6 +27,7 @@
 * `Formulas <formulas.html>`_ -- Built-in math formulas optimized for speed and robustness
 * :doc:`io.SeriesTables module <seriestables>` -- Saves error series and other statistics during training
 * `API <api/>`_ -- The automatically-generated API documentation
+* `V2 planning <v2_planning/index.html>`_ -- Some documentation about the planning of our next version of pylearn.
 
 You can download the latest `PDF documentation <http://deeplearning.net/software/pylearn/pylearn.pdf>`_, rather than reading it online.
 
--- a/doc/v2_planning/API_coding_style.txt	Fri Sep 17 16:21:55 2010 -0400
+++ b/doc/v2_planning/API_coding_style.txt	Fri Sep 17 16:23:51 2010 -0400
@@ -30,12 +30,12 @@
 The four main documents describing our Python coding guidelines are:
     * `PEP 8 -- Style Guide for Python Code
       <http://www.python.org/dev/peps/pep-0008>`_
+    * `Google Python Style Guide
+      <http://google-styleguide.googlecode.com/svn/trunk/pyguide.html>`_
     * `PEP 257 -- Docstring Conventions
       <http://www.python.org/dev/peps/pep-0257>`_
     * `Numpy Docstring Standard
       <http://projects.scipy.org/numpy/wiki/CodingStyleGuidelines#docstring-standard>`_
-    * `Google Python Style Guide
-      <http://google-styleguide.googlecode.com/svn/trunk/pyguide.html>`_
 
 
 However, there are a few points mentioned in those documents that we decided
@@ -49,7 +49,8 @@
       .. code-block:: python
 
         # Good.
-        """This is a multi-line docstring.
+        """
+        This is a multi-line docstring.
 
         Which means it has more than one line.
         """
@@ -308,6 +309,7 @@
         if (cond_1 and
             cond_2 and
             cond_3):
+
             ... 
         # Bad.
         if cond_1 and \
--- a/doc/v2_planning/API_learner.txt	Fri Sep 17 16:21:55 2010 -0400
+++ b/doc/v2_planning/API_learner.txt	Fri Sep 17 16:23:51 2010 -0400
@@ -1,3 +1,8 @@
+.. _v2planning_learner:
+
+Learner API
+===========
+
 # A list of "task types"
 
 '''
@@ -37,6 +42,7 @@
 Notes on metrics & statistics:
    - some are applied to an example, others on a batch
    - most statistics are on the dataset
+
 '''
 
 
--- a/doc/v2_planning/coding_style.txt	Fri Sep 17 16:21:55 2010 -0400
+++ b/doc/v2_planning/coding_style.txt	Fri Sep 17 16:23:51 2010 -0400
@@ -63,7 +63,7 @@
         - You cannot use a **kw argument in your constructor for your own
           selfish purpose.
         - I have no clue whether one could do this with multiple inheritance.
-        - More?
+        - Pb if super class adds an argument that has same name as a child class.
       Question: Should we encourage this in Pylearn?
 
       JB: +0.5
--- a/doc/v2_planning/index.txt	Fri Sep 17 16:21:55 2010 -0400
+++ b/doc/v2_planning/index.txt	Fri Sep 17 16:23:51 2010 -0400
@@ -1,8 +1,9 @@
-.. _libdoc:
+.. _v2planning:
 
 .. toctree::
    :maxdepth: 1
 
+   API_coding_style
    API_formulas
-   API_coding_style
+   API_learner
    api_optimization
--- a/doc/v2_planning/plugin_RP.py	Fri Sep 17 16:21:55 2010 -0400
+++ b/doc/v2_planning/plugin_RP.py	Fri Sep 17 16:23:51 2010 -0400
@@ -82,7 +82,7 @@
 
 # Main Plugins ( already provided in the library ); 
 # This wrappers also registers the plugin
-valid_data = create_data_plugin( sched, data = real_valid_data)
+train_data = create_data_plugin( sched, data = real_train_data)
 train_model    = create_train_model(sched, model = model)
 validate_model = create_valid_model(sched, model = model, data = valid_data)
 early_stopper  = create_early_stopper(sched)
@@ -105,9 +105,12 @@
         cPickle.dump(model.parameters(), open('best_params.pkl','wb'))
 
 
-# Create the dependency graph describing what does what 
+# Create the dependency graph describing what does what
+train_data.act( on = sched.begin(), when = once() )
+train_data.act( on = Event('batch'),
+train_data.act( on = train_model.done(), when = always())
 train_model.act(on = train_data.batch(), when = always())
-validate_model.act(on = train_model.done(), when = every(n=10000)) 
+validate_model.act(on = train_model.done(), when = every(n=10000))
 early_stopper.act(on = validate_model.error(), when = always())
 print_error.act( on = train_model.error(), when = always() )
 print_error.act( on = train_data.eod(), when = always() )