Skip to content

Commit

Permalink
Fix for Neuron9.0 (#1)
Browse files Browse the repository at this point in the history
* Fix for Neuron9.0

* Cleanup for merge.

Co-authored-by: Olli Lupton <oliver.lupton@epfl.ch>
  • Loading branch information
alkino and olupton authored May 27, 2022
1 parent 340be3a commit 66a2849
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
9 changes: 7 additions & 2 deletions ProbGABAAB_EMS_GEPH_g.mod
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,13 @@ VERBATIM
#include<stdio.h>
#include<math.h>

#ifndef NRN_VERSION_GTEQ_8_2_0
double nrn_random_pick(void* r);
void* nrn_random_arg(int argpos);
#define RANDCAST
#else
#define RANDCAST (Rand*)
#endif

ENDVERBATIM

Expand Down Expand Up @@ -304,7 +309,7 @@ VERBATIM
: each instance. However, the corresponding hoc Random
: distribution MUST be set to Random.uniform(1)
*/
value = nrn_random_pick(_p_rng);
value = nrn_random_pick(RANDCAST _p_rng);
//printf("random stream for this simulation = %lf\n",value);
return value;
}else{
Expand All @@ -313,7 +318,7 @@ ENDVERBATIM
: independent of nhost or which host this instance is on
: is desired, since each instance on this cpu draws from
: the same stream
urand = scop_random(1)
urand = scop_random()
VERBATIM
}
ENDVERBATIM
Expand Down
7 changes: 6 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,9 @@ All the experimental data and other resources can be found in a Live Paper at th
Questions on the NEURON simulation should be addressed to
(replace -at- with the usual @ symbol):
carmen.lupascu-at-pa.ibf.cnr.it
michele.migliore-at-cnr.it
michele.migliore-at-cnr.it

Changelog
---------
2022-05: Updated MOD files to contain valid C++ and be compatible with the
upcoming versions 8.2 and 9.0 of NEURON.

0 comments on commit 66a2849

Please # to comment.