GPU Accelerated GA?

Anyone knows if there is GPU accelerated Genetic Algorithm for Grasshopper or C#? I would love to see an update in Galapagos for GH2 that uses our gpus as well. What I currently see is around 30% utilisation of Galapagos of all my CPU cores which seems rather slow, but given that Galapagos like 10 years old code its forgivable, however I’m looking for more modern alternatives.

1 Like

You can try to use the hops component, if you search the forum here you will see some info about it. You may need to rewrite your definition to segment parts of the code that can be run in parallel.

2 Likes

I agree that we need more speed for evolutionary solvers. The problem is some computational procedures depends on the outcome of the procedure before. That’s why it is super hard to implement multi-threading on many aspects of the modeling or analysis.
It is likely you have a Quad-core processor that’s why you see 25%-30% utilization. That means only a single core is working on it.

For GPU based applications things can be better if we have an OpenCL or CUDA libraries that can help with that.

1 Like

@markz I didn’t know about hops but looks interesting. I can program parallel code in C# but the problem is even in parallel its too slow so I want to use CUDA or OpenCL to make the computation.

@tay.othman its 6core, 12 thread PC and all of them are used, because I see them all. Regarding the general GH definitions in parallel, there must be a way but would need totally new way of using grasshopper, like different concept that is not related to visual coding at all or at least it is but results get take only when its their turn.

1 Like

A general advice when trying to calculate things faster, check if you can calculate less things first.

1 Like

That is a really good advice, only if I had the option to do it :slight_smile: I guess what I really need is Kangaroo to be GPU accelerated :smiley: to make things faster in the GA.