kohonen.kohonen.Parameters

class kohonen.kohonen.Parameters(dimension=None, shape=None, metric=None, learning_rate=None, neighborhood_size=None, noise_variance=None)[source]

We are plain old data holding self-organizing map parameters.

__init__(dimension=None, shape=None, metric=None, learning_rate=None, neighborhood_size=None, noise_variance=None)[source]

This class holds standard parameters for self-organizing maps.

dimension: The length of a neuron vector in a Map or a Gas.

shape: The shape of the neuron topology in whatever Map or Gas we are
building.
metric: The distance metric to use when comparing cues to neurons in the
map. Defaults to euclidean_metric.
learning_rate: This parameter determines the time course of the learning

rate for a Map. This parameter should be a callable that takes no arguments and returns a floating point value for the learning rate.

If this parameter is None, a default learning rate series will be used, equivalent to ExponentialTimeseries(-1e-3, 1, 0.2).

If this parameter is a numeric value, it will be used as the constant value for the learning rate: ConstantTimeseries(value).

neighborhood_size: Like the learning rate, this parameter determines the

time course of the neighborhood size parameter. It should be a callable that takes no arguments and returns a neighborhood size for storing each cue.

If this is None, a default neighborhood size series will be used. The initial size will be the maximum of the dimensions given in shape, and the decay will be -1e-3: ExponentialTimeseries(-1e-3, max(shape), 1).

If this is a floating point value, it will be used as a constant neighborhood size: ConstantTimeseries(value).

noise_variance: Like the learning rate and neighborhood size, this

should be a factory for creating a callable that creates noise variance values.

If this is None, no noise will be included in the created Maps.

If this parameter is a number, it will be used as a constant noise variance.

Methods

__init__([dimension, shape, metric, ...]) This class holds standard parameters for self-organizing maps.

Related Topics

This Page