[pymvpa] tiny suggestion for SOM (10 second change)
nikolaas.oosterhof at unitn.it
Tue Mar 12 10:26:37 UTC 2013
On 11 March 2013 20:29, Ike Hall <ike.hall at gmail.com> wrote:
>> On 10 March 2013 23:47, Ike Hall <ike.hall at gmail.com> wrote:
>>> It would appear that the SimpleSOMMapper class performs the
>>> of it's Kohonen layer in the SimpleSOMMapper._train method. As the
>>> method calls ._pretrain, ._train, and ._posttrain in order, I submit that
>>> would be preferable to move the initialization phase to ._pretrain.
>> Or do you have other suggestions on what to move to _pretrain?
> In summary: Moving the first line to _pretrain is something I would
> strongly advocate.
> moving dqd to be stored in self at initialization is something I would
> advocate for, but far less strongly, as someone wanting to use a different
> distance function would (likely?) also want to override the
> _compute_influence_kernel method, and at that point they are not far from
> overriding all of _train.
All right, I added these changes to my branch  and sent a pull
request  for the main branch.
If you have comments on the code please make comments on github  so
that everyone can see them.
More information about the Pkg-ExpPsy-PyMVPA