Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

KernelFactory Class Reference

Generates two-dimensional matrices of function values as kernels for convolution. More...

#include <kernelfactory.h>

List of all members.

Public Types

typedef InternalNeuralRegion::WeightMatrix KernelMatrix
 Type to use for a generated kernel. More...

typedef double (* kernel_fnPtr )(double x_sq, double sig_sq)
 Concrete type to use for a kernel function pointer.

enum  BlurTypes {
  Blur_SquareAverage,
  Blur_CircularAverage,
  Blur_Gaussian,
  Blur_DoG,
  Blur_LoG,
  Blur_GoD,
  Blur_DoGGoD,
  Blur_PGM
}
 Possible values for a blur_type.


Public Methods

 KernelFactory ()
virtual ~KernelFactory ()
KernelMatrix create ( int index, double world_size_scale, StringArgs arglist )
 Update the kernel matrices for each eye. More...

KernelMatrix create (kernel_fnPtr fnptr, double radius, int max_radius, string& errors, bool circular=true, bool normalize=true)
 Convenient wrapper for RadialFunction's version. More...

void register_params_and_commands ( void )
 Call before using any of the parameters and commands in this class. More...


Public Attributes

const BlurTypes max_blur_type
 Highest index defined in BlurTypes. More...


Detailed Description

Generates two-dimensional matrices of function values as kernels for convolution.

Definition at line 21 of file kernelfactory.h.


Member Typedef Documentation

typedef InternalNeuralRegion::WeightMatrix KernelFactory::KernelMatrix
 

Type to use for a generated kernel.

Definition at line 24 of file kernelfactory.h.


Member Enumeration Documentation

enum KernelFactory::BlurTypes
 

Possible values for a blur_type.

Definition at line 46 of file kernelfactory.h.


Constructor & Destructor Documentation

KernelFactory::KernelFactory ( )
 

Definition at line 26 of file kernelfactory.h.

KernelFactory::~KernelFactory ( ) [inline, virtual]
 

Definition at line 27 of file kernelfactory.h.


Member Function Documentation

KernelMatrix KernelFactory::create ( kernel_fnPtr fnptr,
double radius,
int max_radius,
string & errors,
bool circular = true,
bool normalize = true ) [inline]
 

Convenient wrapper for RadialFunction's version.

Definition at line 35 of file kernelfactory.h.

KernelFactory::KernelMatrix KernelFactory::create ( int index,
double wss,
StringArgs arglist )
 

Update the kernel matrices for each eye.

This is currently not as cleanly implemented as input_define or input_define_generator (i.e., no hierarchy of subclasses) but that added complexity probably isn't worth it since the base implementation (the blurring kernel passed to retina.h) is itself very general. So this is basically just a virtual constructor for such a kernel.

The default width of each matrix was chosen empirically for each type, based upon plots of the kernel at small radii (approximately 1-6). For the values chosen, the function was nearly zero to the naked eye (if it tended towards zero, of course).

The given index is used for DoGGoD, to determine which type to use.

Some types may return an empty kernel (0 x 0), so that possibility must be checked before using the kernel.

Definition at line 201 of file kernelfactory.c.

Referenced by KernelFactoryWrapper::operator()().

void KernelFactory::register_params_and_commands ( void )
 

Call before using any of the parameters and commands in this class.

Definition at line 22 of file kernelfactory.c.


Member Data Documentation

const BlurTypes KernelFactory::max_blur_type
 

Highest index defined in BlurTypes.

Definition at line 50 of file kernelfactory.h.


The documentation for this class was generated from the following files:
Generated at Mon Aug 21 00:31:19 2000 for RF-LISSOM by doxygen1.2.1 written by Dimitri van Heesch, © 1997-2000