Open CyprienBosserelle opened 1 month ago
using the same test: 675 river: 19s runtime!
Using the same setup as above but rerunning each scenarios. (Waitaki domain, single level (256m res). 3600 s run )
n rivers | Run times old code | Run times new code |
---|---|---|
1 | 5 | 5 |
10 | 5 | 6 |
100 | 14 | 7 |
675 | 73 | 9-10 |
Results between old and new code are exactly identical but the new code is 7 times faster with 675 rivers.
[!TIP] SUCCESS
Also added a momentum preserving correction for u and v when adding rain input.
Improve efficiency if may rivers are involved
I'm changing the structure of the model workflow to be efficient if a lot of rivers are in the model. Currently kernels are launched in serial for each river. This is very inefficient when you have many rivers. In an example using a crud model of the lower Waitaki River.
This doesn't look too bad but things gets worse in other setting (may need a better example to make the point about the point of this)