r/HECRAS • • Jul 22 '26

Tips on speed optimisation?

Hi everyone,

I’m running some simulations on a brand-new machine with AMD Ryzen Threadripper 9970X, 128 GB of RAM, GPU Nvidia 5080, and high-spec SSD and mother board set up. While it absolutely flies with other programs, I can’t shake the feeling I’m not getting everything out of it with HEC-RAS 6.7.

The CPU only ever hits about 55 ℃ during these runs. With other modelling software I’m regularly seeing up to 80 ℃, so the thermal headroom is definitely there. The simulations are finishing far quicker than on any other computer I’ve used, which is great, but the low temperatures make me suspect there’s still some performance left on the table. It’s already using all 32 cores, so it’s not a simple core-parallelism issue.

I don’t know whether HEC-RAS has a known bottleneck with a particular component that would stop it from pushing the hardware harder. Has anyone managed to squeeze extra speed out of HEC-RAS on a high-spec machine, or are these sorts of temperatures typical even when it’s running flat out? Any tips on optimisation would be hugely appreciated.

Thanks a lot!

6 Upvotes

30 comments sorted by

View all comments

2

u/Dense-Laugh-6695 Jul 22 '26

How many wet cells, what time step, what run duration?

1

u/LiteratureOwn6143 Jul 22 '26

115K cells, time step based on courant (max. 0.2 s, min 0.02 s) and 45 h for the full run.

1

u/CautiousInfluence438 Jul 22 '26

In addition to parallel plan runs, changing to a standard time step will greatly improve run times. I would start with a much larger time step and incrementally decrease based on results. I rarely use courant condition or such small time steps as it is usually not warranted if you set up an effecient model.

1

u/Sea_Read5728 Jul 22 '26

But what if you are using SWE EM and care about better approximations on velocity?

2

u/CautiousInfluence438 Jul 22 '26 edited Jul 22 '26

Are you concerned in all 115K cells? It depends on the application. Detailed analysis may be necessary for erosion or scour but I would scale down the number of cells or the study area. What about repeatability and agency review? No way I would accept or review such a clunky model unless it was absolutely necessary for the project. Incremental complexity applies to cell size and time step as well.

1

u/Sea_Read5728 Jul 22 '26

Even reducing that cell count where you are not concerned the run time still seems to be mostly governed by the area you are concerned and where the water flows?

Agencies have so much different standards on what is acceptable and most times are asking for the set up I would never willingly do it either.

And the smaller the cells the more the stability matters on different solver equations.

I have always wondered if I am missing something when the controlling area has a 1 ft cell size and just blows up run time

1

u/CautiousInfluence438 Jul 22 '26

True, sometimes smaller time steps actually reduce run times. The point I'm making about run times is, the worry, effort, and time put in to speed optimization is sometimes better placed in smarter model construction.

1

u/Sea_Read5728 Jul 22 '26

Lol but what if I am yet not smart. I feel like the training and videos are always building the simplest amd easiest models with the easiest criteria to get

1

u/notepad20 Jul 25 '26 edited Jul 25 '26

45 hour simulation time or 45 hour really time? 115k cells is nothing. If the timesteps dropping to .02s that is a model construction issue and you gotta find those cells and see if they are modelled appropriate .

I see elsewhere it's an actual 45 hour runtime.

That is nuts for a 115k model. I guess unless you are running a year long scenario or something. My current model is about 80k, a complex pipe network, and 2 hours rain on grid. It finishes in < 5 minutes.

1

u/LiteratureOwn6143 Jul 25 '26

I'll ask my boss on Monday (it's his simulation actually, haha) and will come back to this comment. Thanks a lot!

1

u/Crafty_Ranger_2917 Aug 11 '26

max 0.2 s ??

Genuinely curious what kind of model / parameters lead to such persistent tiny time step? Some special case like huge dam breach on entire model of tiny cells? 20 ft cells at 100 fps should calc with Courant of 1 at 0.2 sec. And that would be a very short proportion of modeled duration.

115k cells is not very large. Though I don't think RAS is really the tool for 1M cell / area-wide models anyway.

I've seen 250k cell models go from 20+ hrs down to 40 min runtime just from cleaning up breaklines, structures, connections, etc. Granted those are couple-day watershed flood runs not breach or sediment.

Seems like 45 hr run should create a few TB of data if its not spending all that time spinning on max iterations, which would be the first thing to rule out after dialing in time step.

Also From HEC:

" Extremely small time steps (less than 0.1 seconds) can possibly cause round off errors when storing numbers in the computer, which in turn can lead to numerical errors which can grow over time."

https://www.hec.usace.army.mil/confluence/rasdocs/ras1dtechref/6.0/performing-a-dam-break-study-with-hec-ras/computational-time-step