-
Notifications
You must be signed in to change notification settings - Fork 16
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
Expose synapse span type choices #74
Comments
It would be nice if codegen targets could create extra keyword arguments in Brian itself to cover this sort of thing. What do you think @mstimberg? |
+1 for extra keyword arguments per Synapse / Group objects :) |
Some more fine-grained control would be definitely nice, I also briefly discussed this with @moritzaugustin last week. The problem that I'm seeing is to not mix device-specific details and the model itself too much. The nice thing about our current device implementation is that most of the time you'll set a bunch of preferences and device settings in the beginning, but all the rest of the model is independent of the device and does not need any changes if you change the device. Having something like
I think we only have two options, both with their advantages and disadvantages:
The advantage of solution 1 is that it separates the device settings from the main model code, but it needs you to make use of Python's naming (or mix it in with the model code again), which most users are not really aware of. I think I prefer option 2, even though it mixes model and device implementations a bit – given that it is named |
Yes, it is a bit of a difficult construct and I also liked the clean separation of model and device-specific information. But on the other hand I would struggle to use version 1 (get the naming sorted) and I also think it would be somewhat difficult for users to keep it in check when scripts get longer and one has to change the spantype on top when introducing or changing the synapse group somewhere else. |
I also like option 2 (now) as overall user convenience seems higher. Moreover, devices still can offer global prefs (e.g. in your case span_type) that apply to all synaptic pathways at once, which for simple structured models still allows clear abstraction of device and model specification within option 2. |
This could be revisited within GSoC2021. |
I have made a simple change that allows to set the default synapse span type for all synapse groups in a model via a brian 2 preference
devices.genn.synapse_span_type
.It would be better if we had a method to do it per synapse population.
The simple method is realised in the expose_blocksize_prefs branch if you want to have a look, @mstimberg
The text was updated successfully, but these errors were encountered: