[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [IMP-dev] Parallelize code



At one point at least there were openmp support within brownian dynamics (for the particle perturbations) as well as restraint evaluations.


On Wed, Jul 16, 2014 at 12:33 PM, Barak Raveh <" target="_blank">> wrote:
So in principle this support can be added with IMP OpenMP pragma macros, though since most of the computation time typically involves the scoring function, it is probably wiser to parallelize that part of the code. I know Daniel did some work in that direction in the past but not sure where it's gotten, see alsoÂhttps://integrativemodeling.org/nightly/doc/html/base_2thread__macros_8h.html#a23be334270a8da2ae521fa70a57376a9

It should in theory be pretty simple to add OpenMP statements at some key computations, based on profiling.Â


On Wed, Jul 16, 2014 at 12:28 PM, Ben Webb <" target="_blank">> wrote:
On 07/16/2014 02:11 AM, Davide Baà wrote:
I have set up a Brownian dynamics optimizer as follow:

m = IMP.kernel.Model()

# Brownian Dynamics
bd=IMP.atom.BrownianDynamics(m)
bd.set_maximum_time_step(1000)

for i in range(1, nrounds):
   e = bd.optimize(10)

Is it possible in IMP to parallelize the code to make it faster?

If you really require the output of one optimization to be the input of the next, then no, short of parallelizing the restraint evaluation itself. Currently the only way to do that is via OpenMP.

If you can instead run nrounds optimizations starting from different (e.g. random) starting conditions, parallelization is trivial. You can use IMP.parallel or simply run multiple copies of your script, e.g. with different random seeds.

    Ben
--
" target="_blank"> Â Â Â Â Â Â Â Â Â Â Âhttp://salilab.org/~ben/
"It is a capital mistake to theorize before one has data."
    - Sir Arthur Conan Doyle
_______________________________________________
IMP-dev mailing list
" target="_blank">
https://salilab.org/mailman/listinfo/imp-dev



--
Barak

_______________________________________________
IMP-dev mailing list
">
https://salilab.org/mailman/listinfo/imp-dev