Mercurial > pylearn
comparison dataset.py @ 83:c0f211213a58
bugfix
author | Frederic Bastien <bastienf@iro.umontreal.ca> |
---|---|
date | Mon, 05 May 2008 11:14:28 -0400 |
parents | 158653a9bc7c |
children | 7b1f3ad3d60b |
comparison
equal
deleted
inserted
replaced
82:158653a9bc7c | 83:c0f211213a58 |
---|---|
133 By convention, attributes not in attributeNames() should have a name | 133 By convention, attributes not in attributeNames() should have a name |
134 starting with an underscore. | 134 starting with an underscore. |
135 @todo enforce/test that convention! | 135 @todo enforce/test that convention! |
136 """ | 136 """ |
137 | 137 |
138 numpy_vstack = lambda fieldname,values: return numpy.vstack(values) | 138 numpy_vstack = lambda fieldname,values: numpy.vstack(values) |
139 numpy_hstack = lambda fieldnames,values: return numpy.hstack(values) | 139 numpy_hstack = lambda fieldnames,values: numpy.hstack(values) |
140 | 140 |
141 def __init__(self,description=None,fieldtypes=None): | 141 def __init__(self,description=None,fieldtypes=None): |
142 if description is None: | 142 if description is None: |
143 # by default return "<DataSetType>(<SuperClass1>,<SuperClass2>,...)" | 143 # by default return "<DataSetType>(<SuperClass1>,<SuperClass2>,...)" |
144 description = type(self).__name__ + " ( " + join([x.__name__ for x in type(self).__bases__]) + " )" | 144 description = type(self).__name__ + " ( " + join([x.__name__ for x in type(self).__bases__]) + " )" |