GPU Precision

Dustin Weaver
Dustin Weaver Altair Community Member
edited September 2023 in Community Q&A

Hi,

I'm currently running simulations using EDEM. I cannot find many resources on the applications and use cases for single vs. double vs. hybrid precision  GPU cases. Are there quantitative or qualitative reasons for using one over the other? I have relatively low speed flow with breakage. I could not find many research papers on this topic and I'm surprised I haven't found any EDEM publications showing the usefulness of using a hybrid precision model. The only, somewhat, quantitative data was the angle of repose for a particle pile but I haven't been able to find data on breakage or other similar cases to mine (rotating sag mill). Also the the blog post on this points to training (Lesson 15 of EDEM training) but then I watch the video and it says the topic will be covered in future lessons, which I don't see any future lessons. Any help with this will be greatly appreciated.

Thank you,

Dustin

 

 

Tagged:

Answers

  • Stephen Cole
    Stephen Cole
    Altair Employee
    edited September 2023

    Hi Dustin,

    I don't have details of any studies, it would be good to hear from the wider EDEM community if anybody has performed some in-depth studies to this.

    For a breakage case I'd use mixed or double precision, although you may have low speeds you typically would have high forces and overlaps for breakage.

    EDEM has always been double precision with the CPU mode and it's only recently that the CUDA GPU solver in EDEM allows for single, mixed and double precision. My experience with Single precision is that it's not always worth the risk of going to single precision vs. any speed benefit you would get, as you say there isn't a lot of research on the topic and qualitatively we see see that single precision can be less stable and less accurate.   That's not to say you shouldn't use single, but I'd run a few test cases on your simulation first before using this method. 

    Mixed precision however tends to give the best of both, it uses double precision when needed for accuracy and otherwise uses the typically faster single precision mode, so you don't tend to see much speed benefit of going from mixed to single precision.

    If you are running some simulations on CPU and some on GPU and comparing outputs on the two solvers then it's best to run double precision to so both solvers are the same.

    Regards

    Stephen