edoddridge / aronnax

An idealised isopycnal model that can be run either with n+1/2 layers, or with n layers and variable bathymetry.
http://aronnax.readthedocs.io/en/latest/
MIT License
23 stars 5 forks source link

FULL MPI #212

Closed edoddridge closed 5 years ago

edoddridge commented 5 years ago

Aronnax can now use MPI to run on multiple processors. Closes #47

I have only benchmarked on my laptop, but going from one core to two cores increased the speed by 65%. While there's room for improvement, this is still excellent.

There are currently far too many exchange calls. These were required to keep the results identical to previous single-core results which wrapped fields far too often. Judicious use of the halos should remove the need for this, and will be addressed in the future. These calls will likely limit the speed up that can be obtained with large numbers (O(10s-100s)) of processors on big clusters.

All previous tests pass. In addition to this, there are many new multicore tests:

Once merged this is worthy of a new release! 0.3.0 here we come.

codecov[bot] commented 5 years ago

Codecov Report

Merging #212 into master will increase coverage by 0.68%. The diff coverage is 95.21%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #212      +/-   ##
==========================================
+ Coverage   91.14%   91.82%   +0.68%     
==========================================
  Files          19       20       +1     
  Lines        1603     1822     +219     
  Branches       82       96      +14     
==========================================
+ Hits         1461     1673     +212     
- Misses        116      124       +8     
+ Partials       26       25       -1
Impacted Files Coverage Δ
src/bernoulli.f90 100% <100%> (ø) :arrow_up:
src/advection_schemes.f90 100% <100%> (ø) :arrow_up:
src/exchange.f90 100% <100%> (ø)
src/state_deriv.f90 100% <100%> (+8.33%) :arrow_up:
src/aronnax.f90 94.18% <100%> (+4.18%) :arrow_up:
src/momentum.f90 92.24% <100%> (+0.06%) :arrow_up:
src/enforce_thickness.f90 70% <100%> (ø) :arrow_up:
aronnax/driver.py 93.85% <100%> (+0.16%) :arrow_up:
src/end_run.f90 58.82% <100%> (ø) :arrow_up:
src/thickness.f90 97.67% <100%> (+0.02%) :arrow_up:
... and 9 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 539fd8d...9691557. Read the comment docs.