Skip to content

Commit

Permalink
Merge pull request #13 from VirtualPlanetaryLaboratory/ParallelFix
Browse files Browse the repository at this point in the history
Edited worker loop so that it runs in parallel
  • Loading branch information
RoryBarnes committed Apr 25, 2022
2 parents afeed80 + aed3593 commit 2d875fb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions multiplanet/multiplanet.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,10 @@ def parallel_run_planet(input_file, cores, quiet, verbose, bigplanet, force):
for i in range(cores):
workers.append(mp.Process(target=par_worker,args=(checkpoint_file,system_name,body_list,logfile,in_files,verbose,lock,bigplanet,master_hdf5_file)))
for w in workers:
print("Starting worker")
w.start()

for w in workers:
w.join()

if bigplanet == False:
Expand Down

0 comments on commit 2d875fb

Please sign in to comment.