117 std::ifstream fin (filename.c_str());
119 std::stringstream oss;
120 oss <<
"PatternMonitor:: " 121 <<
"There was a problem opening file " 133 int total_pattern_size = 0;
134 while( !fin.eof() && patterns->size() < maxpat ) {
137 fin.getline (buffer,255);
140 if (line[0] ==
'#')
continue;
142 if ( total_pattern_size > 0 ) {
143 std::stringstream oss;
144 oss <<
"PatternMonitor:: Read pattern " 146 <<
" with pattern size " 147 << total_pattern_size
153 patterns->push_back(pattern);
155 total_pattern_size = 0;
160 std::stringstream iss (line);
168 pattern.push_back( pm ) ;
170 total_pattern_size++;
175 std::stringstream oss;
176 oss <<
"PatternMonitor:: Finished loading " << patterns->size() <<
" patterns";
NeuronID i
Definition: auryn_definitions.h:173
bool localrank(NeuronID i)
Checks if the global NeuronID i is integrated on this MPI rank.
Definition: SpikingGroup.cpp:531
NeuronID global2rank(NeuronID i)
Converts global NeuronID within the SpikingGroup to the local NeuronID on this rank.
Definition: SpikingGroup.h:446
std::vector< pattern_member > type_pattern
Definition: auryn_definitions.h:177
Logger * logger
Global pointer to instance of Logger which needs to be initialized in every simulation main program...
Definition: auryn_global.cpp:36
AurynDouble gamma
Definition: auryn_definitions.h:174
void msg(std::string text, LogMessageType type=NOTIFICATION, bool global=false, int line=-1, std::string srcfile="")
Definition: Logger.cpp:74
SpikingGroup * src
Definition: PatternMonitor.h:65
Struct used to define neuronal assembly patterns in SparseConnection.
Definition: auryn_definitions.h:172
std::string string
Standard library string type which is imported into Auryn namespace.
Definition: auryn_definitions.h:156
unsigned int NeuronID
NeuronID is an unsigned integeger type used to index neurons in Auryn.
Definition: auryn_definitions.h:151