-
Notifications
You must be signed in to change notification settings - Fork 24
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
Scoping out major surgery to occDetFunc
#249
Comments
Thinking about this some more, I'm wondering whether in fact it may be more straightforward that we thought. Some suggestions:
|
If we go down this route, we would also have to figure out how to do this in parallel. |
This all sounds reasonable. An alternative however would be a function that wraps around |
I've started implementing this on my version of the Nimble branch. |
This should make it easier to work with editing the Nimble version. Once that is done, we'll want to edit the code in order to make it compatible with multiple species. |
To gain the full benefit of Nimble, we could change the structure of sparta such that the model is compiled only once, then applied to each species in turn. This could really cut down on runtime.
To start scoping out the challenge, I made a list of all the points in occDetFunc where the identity of the species actually matters.
occDetData
. Based on this, there is a decision whether to proceed , which is implemented at line 242. If the species doesn't have enough data, subsequent steps are omitted.Changing occDetFunc so that it works with multiple species would be quite challenging.
Much of the code between lines 234 and 366 is associated with setting up of the vectors defining Regions and regional aggregates. Perhaps these could be placed into a separate function. Probably this is a general solution to make the challenge clearer: package up individual sections of the code and put them elsewhere. Then the critical dependencies will become clearer.
The text was updated successfully, but these errors were encountered: