Source: V1Connection.h


Annotated List
Files
Globals
Hierarchy
Index
// =======================================================================================
// V1Connection.h
// Time-stamp: <2001-12-19 18:30:08 aknoblau>
// Base connection type for primary visual cortex V1
// programmed in December 2001 by Andreas Knoblauch
// Department of Neural Information Processing
// University of Ulm, Germany
// Version 1.0 alpha
// last documented change: December 28, 2001
// =======================================================================================
// types/classes/interfaces:
// ---------------------------------------------------------------------------------------
// global objects:
// ---------------------------------------------------------------------------------------
// related modules: 
// ---------------------------------------------------------------------------------------
// notes:
// ---------------------------------------------------------------------------------------
// history: 
//   Version 1.0 alpha programmed on December 28, 2001 by Andreas Knoblauch
// ---------------------------------------------------------------------------------------
// bugs:
// ---------------------------------------------------------------------------------------
// 2 do:
// =======================================================================================

#ifndef V1Connection_H
#define V1Connection_H

#include "BlankTopoConnection.h"



// **************************************************************************************************************************
// **************************************************************************************************************************
// TMV1Connection
// template for  topographical delayed connections with kernels according to orientation selective scheme of V1
// Status: version 1.0 alpha
// last change: December 28, 2001
// **************************************************************************************************************************

template
class TMV1Connection : public TMBlankTopoConnection {
 public:
  static const char* STR_RANGE_NORMAL;
  static const char* STR_RANGE_NEAR;
  static const char* STR_RANGE_FAR;
  static const char* STR_FERMI_NORMAL;
  static const char* STR_FERMI_2STATES;
  static const char* STR_FERMI_NONE;

  static const int RANGE_NORMAL =0;
  static const int RANGE_NEAR   =1;
  static const int RANGE_FAR    =2;
  static const int FERMI_NORMAL =0;
  static const int FERMI_2STATES=1;
  static const int FERMI_NONE   =2;

  // parameters
  string scopeID,                                // scope id for scope of class TMV1Connection
         scopeID_delays;                         // scope id for scope of delays
  TPar     alpha1;
  TPar     alpha2;
  TPar     sig1;
  TPar     sig2;
  TPar     sig3;
  TPar     sig4;
  TPar     theta;
  TPar     beta;
  TPar     theta2;
  TPar     beta2;
  TsPar    range;
  TsPar    fermi;
  TPar     thresh;
  TsVecPar norm;

  // parameter values
  int range_val;
  int fermi_val;
  int norm_val_flag;
  int norm_val_individual;
  TFloat norm_val_order;
  TFloat norm_val_norm;

  const TMNumMarray& kMap_orientations;     // reference to the orientation map (usually from a GaussConnection)
  const TMMatrixParameter& orientations; // reference to the orientations (usually par. phi from a GaussConnection)

  // constructors/destructors
  TMV1Connection(TSimulationEnvironment& simEnv_arg, const char* name_arg,                        // complete constructor
		 TMPort* preOut_arg, TMPort* postIn_arg,
		 TLayout* kernelLT_arg, const TKernelDescriptor& kd,
                 const TMNumMarray& kMap_orientations_arg,
		 const TMMatrixParameter& orientations_arg);
  TMV1Connection(TSimulationEnvironment& simEnv_arg, const char* name_arg,                        // default constructor
		 TMPort* preOut_arg, TMPort* postIn_arg,
		 TLayout* kernelLT_arg, const TKernelDescriptor& kd,
                 const TMNumMarray& kMap_orientations_arg,
		 const TMMatrixParameter& orientations_arg, int parse);
  TMV1Connection(TMV1Connection& pattern, // pattern constructor
                 const char* name_arg, TMPort* preOut_arg, TMPort* postIn_arg,
		 TLayout* kernelLT_arg,
                 const TMNumMarray& kMap_orientations_arg,
		 const TMMatrixParameter& orientations_arg);
  ~TMV1Connection();                                                                              // destructor

  // methods
  void setDefaultParameters();                 // set default parameters    
  void reparse();                              // reparse parameters
  void handleUpdatedParameters();              // handle updated parameters
  void setV1Kernel(int idx, TNumSyn* krnl);    // set kernel with index idx to krnl (no normalization!)
  void outputState(ostream& os);               // display all fields of the object
  void outputState(ostream& os, int complete); // if complete==0 then display only the most important fields of the object

  friend ostream& operator<<  
    (ostream& os, const TMV1Connection& v1c); 
  friend istream& operator>> 
    (istream& is,       TMV1Connection& v1c); 

 protected:
  void firstInit(TMV1Connection* pattern);
  void setParameterValues();
  void setParameterValues_kernelsMapping();
  void setParameterValues_kernels();

 private:
  static const char* scopeString;                                        // scope name of class TMBlankTopoConnection
  TFloat distance(TFloat px,TFloat py, TFloat cx,TFloat cy, TFloat phi); // utility method from Felix1
};

template
ostream & operator<<(ostream& os, const TMV1Connection& v1c); // output operator
template
istream & operator>>(istream& is,       TMV1Connection& v1c); // input operator



#endif  /* V1Connection_H */

Generated by: aknoblau on synfire on Sat May 1 14:32:16 2004, using kdoc 2.0a54.