33 string infilename =
"";
34 string ratemodfile =
"./ratemod.dat";
35 string simname =
"dense";
42 double sparseness = 0.1;
43 double simtime = 1000.;
45 double tau_stdp = 20e-3;
48 double wmax = 10*gamma*w;
57 po::options_description desc(
"Allowed options");
59 (
"help",
"produce help message")
60 (
"simtime", po::value<double>(),
"simulation time in seconds")
61 (
"dir", po::value<string>(),
"dir for output files")
62 (
"load", po::value<string>(),
"basename to load network from")
63 (
"ratefile", po::value<string>(),
"file containing the timeseries with the rate modulation")
67 po::store(po::parse_command_line(ac, av, desc), vm);
70 if (vm.count(
"help")) {
71 std::cout << desc <<
"\n";
75 if (vm.count(
"load")) {
76 infilename = vm[
"load"].as<
string>();
79 if (vm.count(
"simtime")) {
80 simtime = vm[
"simtime"].as<
double>();
83 if (vm.count(
"dir")) {
84 dir = vm[
"dir"].as<
string>();
87 if (vm.count(
"ratefile")) {
88 ratemodfile = vm[
"ratefile"].as<
string>();
92 catch(std::exception& e) {
93 std::cerr <<
"error: " << e.what() <<
"\n";
97 std::cerr <<
"Exception of unknown type!\n";
102 std::stringstream oss;
103 oss << dir <<
"/" << simname <<
"." <<
sys->
mpi_rank() <<
".";
104 string outputfile = oss.str();
138 0.9*gamma*w,sparseness,
143 0.9*gamma*w,sparseness,
147 if (!infilename.empty()) {
152 msg =
"Setting up monitors ...";
155 std::stringstream filename;
156 filename << outputfile <<
"e.ras";
161 filename << outputfile <<
"i.ras";
166 filename << outputfile <<
"p.ras";
171 filename << outputfile <<
"e.prate";
176 filename << outputfile <<
"e.mem";
181 for (
int j = 0; j<1000 ; j++) {
182 neurons_e->
tadd(j,5.);
186 if (!
sys->run(simtime,
true))
void auryn_free()
Cleanly shuts down Auryn simulation environment.
Definition: auryn_global.cpp:107
Standard Glutamatergic (excitatory) transmission.
Definition: auryn_definitions.h:139
unsigned int mpi_rank()
Returns current rank.
Definition: System.cpp:1009
void load_network_state(std::string basename)
Loads network state from a netstate file.
Definition: System.cpp:812
A Checker class that tracks population firing rate as a moving average and breaks a run if it goes ou...
Definition: RateChecker.h:59
The base class to create sparse random connections.
Definition: SparseConnection.h:66
Logger * logger
Global pointer to instance of Logger which needs to be initialized in every simulation main program...
Definition: auryn_global.cpp:36
void set_ampa_nmda_ratio(AurynFloat ratio)
Set ratio between ampa/nmda contribution to excitatory conductance.
Definition: IFGroup.cpp:209
The standard Monitor object to record spikes from a SpikingGroup and write them to a text file...
Definition: SpikeMonitor.h:52
void set_tau_mem(AurynFloat taum)
Sets the membrane time constant.
Definition: IFGroup.cpp:154
A special Poisson generator that reads its instantaneous firing rate from a tiser file...
Definition: FileModulatedPoissonGroup.h:46
void auryn_abort(int errcode)
Terminates Auryn simulation abnormally.
Definition: auryn_global.cpp:113
System * sys
Global pointer to instance of System which needs to be initialized in every simulation main program...
Definition: auryn_global.cpp:37
Records the membrane potential from one unit from the source neuron group to a file.
Definition: VoltageMonitor.h:48
void auryn_init(int ac, char *av[], string dir, string simulation_name, string logfile_prefix, LogMessageType filelog_level, LogMessageType consolelog_level)
Initalizes MPI and the Auryn simulation environment.
Definition: auryn_global.cpp:84
#define NI
Definition: sim_dense.cpp:24
Standard Gabaergic (inhibitory) transmission.
Definition: auryn_definitions.h:140
void msg(std::string text, LogMessageType type=NOTIFICATION, bool global=false, int line=-1, std::string srcfile="")
Definition: Logger.cpp:74
Monitor class to record population firing rates.
Definition: PopulationRateMonitor.h:46
void save_network_state(std::string basename)
Saves network state to a netstate file.
Definition: System.cpp:694
void randomize_state_vector_gauss(std::string state_vector_name, AurynState mean, AurynState sigma, int seed=12239)
Randomizes the content of a state vector with Gaussian random numbers. Seeding is MPI save...
Definition: SpikingGroup.cpp:792
Implements the standard integrate and file model used in Auryn.
Definition: IFGroup.h:47
void tadd(NeuronID id, AurynWeight amount, TransmitterType t=GLUT)
Definition: NeuronGroup.cpp:98
#define NE
Definition: sim_dense.cpp:23