databionics.esom.grid
Class MatrixGrid

java.lang.Object
  extended by databionics.esom.grid.Grid
      extended by databionics.esom.grid.MatrixGrid
Direct Known Subclasses:
CircularGrid1D, Grid1D, RectangularGrid

public abstract class MatrixGrid
extends Grid

Abstract base class for all grid structures that can store the weight vectors in a 2D matrix.


Field Summary
protected static org.apache.log4j.Logger log
          interface to log4j system
protected  cern.colt.matrix.DoubleMatrix2D weights
          matrix to store weights
 
Fields inherited from class databionics.esom.grid.Grid
dim, distanceFunction, distanceFunctionName, size
 
Constructor Summary
MatrixGrid()
          Standard constructor
MatrixGrid(int size, int dim)
          Constructor with sizes
 
Method Summary
 cern.colt.matrix.DoubleMatrix1D getNeuron(int index)
          Access to a weight vector by the neuron's index
 cern.colt.matrix.DoubleMatrix2D getWeights()
          Get weights
protected  void init()
          Initialize the matrix
 void setDim(int dim)
          Set the value of dim.
 void setSize(int size)
          Set the value of size.
 
Methods inherited from class databionics.esom.grid.Grid
dim, findNeighbors, getDistanceFunction, getDistanceFunctionName, init, init, init, setDistanceFunction, setDistanceFunction, size, transformRadius
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected static final org.apache.log4j.Logger log
interface to log4j system


weights

protected cern.colt.matrix.DoubleMatrix2D weights
matrix to store weights

Constructor Detail

MatrixGrid

public MatrixGrid()
Standard constructor


MatrixGrid

public MatrixGrid(int size,
                  int dim)
Constructor with sizes

Parameters:
size - number of grid points
dim - number of weights per neuron
Method Detail

setSize

public void setSize(int size)
Set the value of size.

Overrides:
setSize in class Grid
Parameters:
size - value of size.

setDim

public void setDim(int dim)
Set the value of dim.

Overrides:
setDim in class Grid
Parameters:
dim - size value of dim.

init

protected void init()
Initialize the matrix


getNeuron

public cern.colt.matrix.DoubleMatrix1D getNeuron(int index)
Access to a weight vector by the neuron's index

Specified by:
getNeuron in class Grid
Parameters:
index - index of neuron

getWeights

public cern.colt.matrix.DoubleMatrix2D getWeights()
Get weights

Returns:
matrix of weight vectors


Copyright © 2005-2006 Databionics Research Group. All Rights Reserved.