Cypress  1.0
C++ Spiking Neural Network Simulation Framework
Public Member Functions | List of all members
GeNNModels::FixedNumberPostWithReplacementNoAutapse Class Reference

#include <genn_models.hpp>

Inheritance diagram for GeNNModels::FixedNumberPostWithReplacementNoAutapse:
Inheritance graph
[legend]
Collaboration diagram for GeNNModels::FixedNumberPostWithReplacementNoAutapse:
Collaboration graph
[legend]

Public Member Functions

 DECLARE_SNIPPET (FixedNumberPostWithReplacementNoAutapse, 1)
 
 SET_ROW_BUILD_CODE ("const scalar u = $(gennrand_uniform);\n""x += (1.0 - x) * (1.0 - pow(u, 1.0 / (scalar)($(rowLength) - c)));\n""const unsigned int postIdx = (unsigned int)(x * $(num_post));\n""if(postIdx != $(id_pre)){\n""if(postIdx < $(num_post)) {\n"" $(addSynapse, postIdx);\n""}\n""else {\n"" $(addSynapse, $(num_post) - 1);\n""}\n""c++;\n""if(c >= $(rowLength)) {\n"" $(endRow);\n""}}\n")
 
 SET_ROW_BUILD_STATE_VARS ({{"x","scalar", 0.0},{"c","unsigned int", 0}})
 
 SET_PARAM_NAMES ({"rowLength"})
 
 SET_CALC_MAX_ROW_LENGTH_FUNC ([](unsigned int, unsigned int, const std::vector< double > &pars){return(unsigned int) pars[0];})
 

Member Function Documentation

GeNNModels::FixedNumberPostWithReplacementNoAutapse::DECLARE_SNIPPET ( FixedNumberPostWithReplacementNoAutapse  ,
 
)
GeNNModels::FixedNumberPostWithReplacementNoAutapse::SET_CALC_MAX_ROW_LENGTH_FUNC ( [] (unsigned int, unsigned int, const std::vector< double > &pars){return(unsigned int) pars[0];}  )
GeNNModels::FixedNumberPostWithReplacementNoAutapse::SET_PARAM_NAMES ( {"rowLength"}  )
GeNNModels::FixedNumberPostWithReplacementNoAutapse::SET_ROW_BUILD_CODE ( )
GeNNModels::FixedNumberPostWithReplacementNoAutapse::SET_ROW_BUILD_STATE_VARS ( {{"x","scalar", 0.0},{"c","unsigned int", 0}}  )

The documentation for this class was generated from the following file: