Page 1 of 1

Can I use GPUs to accelerate simulation calculations?

Posted: Thu Mar 26, 2020 1:32 pm
by Ryan
Hey,
I am using ARGoS for evolutionary robotics and the genetic algorithms are taking a long time to complete. And my computer is a server with a GPU. Can I use GPUs to accelerate simulation calculations? If it can be achieved, what should I do?

Re: Can I use GPUs to accelerate simulation calculations?

Posted: Thu Mar 26, 2020 3:25 pm
by pincy
No, there is no GPU support in ARGoS. It is likely that you can significantly speed up your code by
  1. Compiling it in Release (CMAKE_BUILD_TYPE=Release)
  2. Profiling where your code is being slow (you can use gprof or GooglePerfTools)
  3. Checking the performance tips for the dynamics2d engine and the rab medium (argos3 -q dynamycs2d, argos3 -q rab_medium)

Re: Can I use GPUs to accelerate simulation calculations?

Posted: Thu Mar 26, 2020 4:32 pm
by Ryan
Thanks!

Re: Can I use GPUs to accelerate simulation calculations?

Posted: Fri Mar 27, 2020 12:23 pm
by Ryan
If I take a multi-process approach, will it accelerate simulation calculation?

I noticed that you have a multi-process evolutionary algorithm.
https://github.com/ilpincy/argos3-examp ... s/mpga.cpp

Re: Can I use GPUs to accelerate simulation calculations?

Posted: Fri Mar 27, 2020 2:52 pm
by pincy
Yes, you could wrap ARGoS with MPI. That would be fast.