Skip to content
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

Refactors to improve code clarity and make changing parameterisations easier #212

Merged
merged 84 commits into from
Sep 22, 2024

Conversation

jagoosw
Copy link
Collaborator

@jagoosw jagoosw commented Sep 13, 2024

I think there is still some room to make this more flexible, for example changing nanophytoplankton and diatoms to just phytoplankton which is a NamedTuple of phytoplankton classes, but then we need functions like ammonia_uptake(all_the_phytoplanktons). This would be useful for experimentation in the future with different things but I am not going to implement here as we just want a working version, and then when people want to experiment that can make these kind of changes.

To do:

  • docstrings
  • show methods
  • check for any more deviations from Aumount 2015
  • Fix negative tracer scaling
  • comment all parameters units
  • documentation

@jagoosw jagoosw marked this pull request as draft September 13, 2024 11:09
@jagoosw jagoosw requested review from ciadht and hannahmw1 September 19, 2024 17:30
@jagoosw
Copy link
Collaborator Author

jagoosw commented Sep 20, 2024

So I had todo some horrible things to get this to work on GPU because it seems that _apply_iterate is not implemented in CUDA C or CUDA.jl or somewhere along the line for very long tuples, so this code also introduces a hack which I will hopefully implement in Oceananigans.

@jagoosw
Copy link
Collaborator Author

jagoosw commented Sep 20, 2024

I think there is a whole new level of abstraction we could do by changing the model to be discrete form, which will likely make this run more efficiently, as well as facilitate grouping the phytoplankton etc. as discussed above.

@jagoosw jagoosw marked this pull request as ready for review September 22, 2024 09:44
@jagoosw jagoosw merged commit fa56518 into hmw-ct-jsw/PISCES Sep 22, 2024
5 checks passed
@jagoosw jagoosw deleted the jsw/refactor-PISCES branch September 22, 2024 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant