-
Notifications
You must be signed in to change notification settings - Fork 70
[WIP] Fix bugs in read_params workflow #1180
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
[WIP] Fix bugs in read_params workflow #1180
Conversation
|
Thanks for finding these Katharina, these are both quite the pickle(s). In both cases, it appears that both of these issues only occur when using the CC @ntolley and @dylansdaniels : The bugs/unexpected behavior you've identified are legitimate. However, if we merged both of these changes, that would have at least small or possibly large impacts on others' simulation outputs, since this would in essence be changing the default model in a scientific sense, and would affect reproducibility. We absolutely need to discuss this at the next HNN Dev meeting, since it is not a change to be made lightly. For reproducibility reasons, and to not suddenly force scientific output of simulations by others to change, we may want to not merge your changes. Depending on future discussion on this issue, one alternative could include: we change For more treatment of how we want to handle changes to the kinda-legacy |
|
Hi Austin, I was actually using this option for the new model, which I currently can't distribute with the hierarchical json, because the read_network_configuration function builds a jones model... At the very least we should change the hard-coded synaptic delays, because there were some typos (some of the L5 delays were set to 0.1, but they should be 1). I don't know if this will change things dramatically. The seeding, however, might, especially if a developer has been using a specific seed to tune their model... Also if the seed is overridden, then why define it in the json file in the first place... |
|
Argh, right, I forgot about the |
|
I have made a 95% complete PR that applies one possible solution at katduecker#2 . |
|
This comment first documents how the implicit It is easiest if we begin by explaining how things currently work on Current add-drives, no legacyLet's assume you are doing the following code example: net = jones_2009_model(add_drives_from_params=True) # NO legacy_mode
dpl = simulate_dipole(net, tstop=170.0)As far as I can tell, all code for loading, changing, and setting the unique
Current add-drives, yes legacy
net = jones_2009_model(add_drives_from_params=True, legacy_mode=True)
dpl = simulate_dipole(net, tstop=170.0)
New
|
| for drive_name, drive in net.external_drives.items(): |
legacy_mode=True, AND so it uses the original values of the seeds of the three typical drives at that point in the code. To do this, we change the code from
for drive_name, drive in net.external_drives.items():
drive["event_seed"] += net.gid_ranges[drive_name][0]to:
if net._legacy_mode:
for drive_name, drive in net.external_drives.items():
if drive_name in ("evdist1", "evprox1", "evprox2"):
drive["event_seed"] = -16
drive["event_seed"] += net.gid_ranges[drive_name][0]Regenerate our default hierarchical-JSON networks accordingly.
|
Note that so far, only the |
This fixes one, but not all, of the tests which currently fail when using this new synaptic delay change.
|
For the synaptic delays...we may want to split that into its own PR/issue. As of the most recent commit b94978a , the only remaining test that fails is one where we test that the dipole output is identical. Specifically, that test is
In that test, we compare the dipole output of the typical sim to existing dipole output data here, on the To my untrained eye, these are different enough for concern, but I'm not an expert at interpretation of this. Possibilities for what to do next:
|
|
Decision Point: @ntolley @katduecker @dylansdaniels we need to decide what to do about the changes to the dipole from the synaptic delays for this PR. (However, this can definitely wait until after SFN...) |

I have been experiencing issues when loading in network parameters from a json file, somehow the simulation always looked different. There were a couple of small bugs due to hard-coded synaptic delays in params.py. There is also an update of the event_seeds that is only applied when reading params from a file, but not when defining an event seed. I have commented it out for now but we'd have to decide if it's needed.