changeset 163:d7d67651d67c

bugfix, we should advence by the minibatch size.
author Frederic Bastien <bastienf@iro.umontreal.ca>
date Mon, 12 May 2008 17:40:06 -0400
parents 45427d4d64b3
children 3518710e16ec
files dataset.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/dataset.py	Mon May 12 17:37:36 2008 -0400
+++ b/dataset.py	Mon May 12 17:40:06 2008 -0400
@@ -1079,7 +1079,7 @@
                       self.dataset.cached_examples.append(example)
               all_fields_minibatch = Example(self.dataset.fieldNames(),
                                              zip(*self.dataset.cached_examples[self.current:self.current+minibatch_size]))
-              self.current+=1
+              self.current+=minibatch_size
               if self.dataset.fieldNames()==fieldnames:
                   return all_fields_minibatch
               return Example(fieldnames,[all_fields_minibatch[name] for name in fieldnames])