Commit 890904b7 authored by Georgios Dagkakis's avatar Georgios Dagkakis

use multiprocessing with the max number of simultaneous processes of the pc

parent b78fd61b
...@@ -83,7 +83,9 @@ class BatchesACO(ACO): ...@@ -83,7 +83,9 @@ class BatchesACO(ACO):
# else run ACO # else run ACO
data['general']['numberOfSolutions']=1 # default of 1 solution for this instance data['general']['numberOfSolutions']=1 # default of 1 solution for this instance
data["general"]["distributorURL"]=None # no distributor currently, to be added in the GUI data["general"]["distributorURL"]=None # no distributor currently, to be added in the GUI
data["general"]["multiprocessorCount"] = 8 # number of parrallel processes, to be added to the GUI # use multiprocessing in the PC. This can be an option, but default for now
import multiprocessing
data["general"]["multiprocessorCount"] = multiprocessing.cpu_count()-1 or 1
ACO.run(self, data) ACO.run(self, data)
data["result"]["result_list"][-1]["score"] = '' data["result"]["result_list"][-1]["score"] = ''
data["result"]["result_list"][-1]["key"] = "Go To Results Page" data["result"]["result_list"][-1]["key"] = "Go To Results Page"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment